Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Package Tracking with Email Notification Mods


olsonsp4c

Recommended Posts

Having some trouble... Any help?

 

Fatal error: Call to undefined function: tep_draw_textarea_field() in /fullpathofsiteishere/httpdocs/admin/orders.php on line 366

 

That line is:

 

		<td class="main"><?php echo tep_draw_textarea_field('comments', 'soft', '60', '5'); ?></td>
  </tr>
  <tr>
	<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
  </tr>

Link to comment
Share on other sites

  • Replies 274
  • Created
  • Last Reply

Top Posters In This Topic

Having some trouble... Any help?

 

Fatal error: Call to undefined function: tep_draw_textarea_field() in /fullpathofsiteishere/httpdocs/admin/orders.php on line 366

 

That line is:

 

		<td class="main"><?php echo tep_draw_textarea_field('comments', 'soft', '60', '5'); ?></td>
  </tr>
  <tr>
	<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
  </tr>

 

I found it, it was a mistake i made, skipped the change to admin htmloutput. Thanks.

Link to comment
Share on other sites

  • 4 weeks later...

Just getting the contribution installed, and I have a few questions:

 

***Step 3***

catalog/includes/database_tables.php

ADD

define('TABLE_UPS_TRACK_NUM', 'ups_track_num');

define('TABLE_USPS_TRACK_NUM', 'usps_track_num');

define('TABLE_FEDEX_TRACK_NUM', 'fedex_track_num');

I've downloaded all the updates for the contribution....I don't see these tables in the SQL only an edit to Orders table.

Is this an error in the installation instructions?

 

***Step 7***

catalog/admin/includes/filenames.php

ADD

define('FILENAME_CATALOG_TRACKING_NUMBER', 'tracking.php');

Same story...file not included. Do I use the catalog/tracking.php from the ZIP.

Is this an error in the installation instructions?

Sam M. - Seattle

Link to comment
Share on other sites

Just getting the contribution installed, and I have a few questions:

I've downloaded all the updates for the contribution....I don't see these tables in the SQL only an edit to Orders table.

Is this an error in the installation instructions?

Same story...file not included. Do I use the catalog/tracking.php from the ZIP.

Is this an error in the installation instructions?

 

No error in sql.

 

step 7 should be moved to bottom "optional" section. thanks! Scott

Link to comment
Share on other sites

Scott,

You're the man! Thank you...

I was working my way down the page and didn't even read the optional stuff.

I think I'm going to set the tracking # into their own form on orders.php.

It seems like it's running into other modifications...not posting the # to DB.

Sam M. - Seattle

Link to comment
Share on other sites

  • 2 weeks later...
trying to see where I went wrong, as I am getting this error, when I click on oder, then edit, invoice or packing slip, I get the following error

 

1054 - Unknown column 'comments' in 'field list'

 

Doing a search on the forums, it looks like the error is from the comments is trying to go under orders.

orders does not have a column comments, comments go to order_status_history.

 

Anyone have any idea where I went wrong ?

 

 

I have the exact same problem. Has anyone addressed this problem in over two months?

Link to comment
Share on other sites

  • 2 weeks later...

I have just installed this and I have never had luck installing this over the past year that I have tired. Anyways I am getting this error

 

Parse error: parse error, unexpected T_CASE in /home/txcampin/public_html/admin/orders.php on line 136

 

which is this line:

 

case 'deleteconfirm':

 

here is the bit of code around it

 

 tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action')) . 'action=edit'));
	break;
  case 'deleteconfirm':
	$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);

	tep_remove_order($oID, $HTTP_POST_VARS['restock']);

	tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('oID', 'action'))));
	break;
}
 }

 

 

Any idea of what this is or how to fix it?

 

-Thanks

Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Link to comment
Share on other sites

  • 2 weeks later...

Thanks for the wonderful contribution. I have everything working except I do not get a link in the order update email. I tried adding EMAIL_TEXT_INVOICE_URL . ' ' . "<a HREF='" . tep_catalog_href_link(FILENAME_CATALOG_ACCOUNT_HISTORY_INFO, 'order_id=' . $oID, 'SSL') . "'>" . to catalog/admin/orders.php but it is still not a link after Detailed invoice.

 

 

thanks for any help

 

 

also for your information the usps url needs to be updated. .

Link to comment
Share on other sites

Thanks for the wonderful contribution. I have everything working except I do not get a link in the order update email. I tried adding EMAIL_TEXT_INVOICE_URL . ' ' . "<a HREF='" . tep_catalog_href_link(FILENAME_CATALOG_ACCOUNT_HISTORY_INFO, 'order_id=' . $oID, 'SSL') . "'>" . to catalog/admin/orders.php but it is still not a link after Detailed invoice.

thanks for any help

also for your information the usps url needs to be updated. .

 

solved the problem

needed to change code on 3 identical lines in catalog/admin/orders.php :)

Link to comment
Share on other sites

  • 5 weeks later...
when i update the order to shipped i get a duplicate entry that says shipped?

 

could you please post a screenshot... thanks!

Scott

Link to comment
Share on other sites

I have just installed this and I have never had luck installing this over the past year that I have tired. Anyways I am getting this error

 

Parse error: parse error, unexpected T_CASE in /home/txcampin/public_html/admin/orders.php on line 136

 

which is this line:

 

case 'deleteconfirm':

 

here is the bit of code around it

 

 tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action')) . 'action=edit'));
	break;
  case 'deleteconfirm':
	$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);

	tep_remove_order($oID, $HTTP_POST_VARS['restock']);

	tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('oID', 'action'))));
	break;
}
 }

Any idea of what this is or how to fix it?

 

-Thanks

 

When I put a closing bracket, before case 'deleteconfirm'; that did the trick it should look like this:

 

 
	tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action')) . 'action=edit'));
	break;
}
  case 'deleteconfirm':
	$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);

	tep_remove_order($oID, $HTTP_POST_VARS['restock']);

	tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('oID', 'action'))));
	break;
}
 }

Link to comment
Share on other sites

I have the Same Problem:

 

Parse error: parse error, unexpected T_CASE in .../shop/catalog/admin/orders.php on line 154

 

Around that Line is this:

 

 tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action')) . 'action=edit'));
   break;
   case 'deleteconfirm':
   $oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);

   tep_remove_order($oID, $HTTP_POST_VARS['restock']);

   tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('oID', 'action'))));
   break;
  }
}

 

Has anybody fixed that Problem ? I really need that Contrib asap. It would be great if anybody can help me !

Edited by SledgeHammer101
Link to comment
Share on other sites

I have the Same Problem:

 

Parse error: parse error, unexpected T_CASE in .../shop/catalog/admin/orders.php on line 154

 

Around that Line is this:

 

 tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('action')) . 'action=edit'));
   break;
   case 'deleteconfirm':
   $oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);

   tep_remove_order($oID, $HTTP_POST_VARS['restock']);

   tep_redirect(tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('oID', 'action'))));
   break;
  }
}

 

Has anybody fixed that Problem ? I really need that Contrib asap. It would be great if anybody can help me !

 

See the previous post - about 2 earlier where a poster solved this problem - i believe that it is a fix that makes it compatible with other installed contribs. thanks! - Scott

Link to comment
Share on other sites

tracking.JPG

 

I know this isn't very helpful; however, I looked through the admin code and can't find a call for the shipped setting twice - one idea is checking that there are not multiple "shipped" status indicators setup in the admin, you can check this by going to "Localization/Orders Status" - thanks! Scott

Link to comment
Share on other sites

I am having a small problem with my installation of this mod. All the functionality seems to be working properly, but somewhere I think I messed up because the emails that are sent to the customer have 'YOUR_STORE_NAME' in ithe subject instead of the actual store name. :blush:

 

To have it automatically replace it with your actual store name do this:

Find

 'YOUR_STORE_NAME bla bla'

 

replace with

 

STORE_NAME . ' bla bla'

Link to comment
Share on other sites

I know this isn't very helpful; however, I looked through the admin code and can't find a call for the shipped setting twice - one idea is checking that there are not multiple "shipped" status indicators setup in the admin, you can check this by going to "Localization/Orders Status" - thanks! Scott

 

I did manage to duplicate this error

In step 6:

The last few lines go like this:

		  }
<!-- Tracking contribution end -->

	  tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . (int)$oID . "', '" . tep_db_input($status) . "', now(), '" . tep_db_input($customer_notified) . "', '" . tep_db_input($comments)  . "')");
	  $order_updated = true;
	}

 

When pasting all of that I got this in my catalog/admin/orders.php:

	  }
//<!-- Tracking contribution end -->

	  tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . (int)$oID . "', '" . tep_db_input($status) . "', now(), '" . tep_db_input($customer_notified) . "', '" . tep_db_input($comments)  . "')");
	$order_updated = true;
	}

	tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . tep_db_input($oID) . "', '" . tep_db_input($status) . "', now(), '" . $customer_notified . "', '" . tep_db_input($comments)  . "')");

	$order_updated = true;
  }

Note the duplicate lines by pasting the code after Tracking contribution end

 

Commenting out those extras lines but not the '}' and it works:

	  }
//<!-- Tracking contribution end -->

//	  tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . (int)$oID . "', '" . tep_db_input($status) . "', now(), '" . tep_db_input($customer_notified) . "', '" . tep_db_input($comments)  . "')");
  //	$order_updated = true;
	}

	tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . tep_db_input($oID) . "', '" . tep_db_input($status) . "', now(), '" . $customer_notified . "', '" . tep_db_input($comments)  . "')");

	$order_updated = true;
  }

Link to comment
Share on other sites

  • 3 weeks later...
It was easy I only use USPS so I just put this link in my admin/orders.php page:

 

<td class="main"><a href="http://trkcnfrm1.smi.usps.com/PTSInternetWeb/InterLabelInquiry.do?origTrackNum=<?php echo $order->info['usps_track_num']; ?>" target="_blank"><?php echo $order->info['usps_track_num']; ?></a></td>

 

Now I can easily check the status of the customers order from my admin panel.

Eric, what a great idea to just click tracking number from admin/orders.php and get the latest shipment information. Thanks for the USPS tracking code. How didn't I think about this myself? This is how I modified my orders.php for all tree shipping couriers: UPS, USPS, and Fedex:

<td class="main"><b><?php echo TABLE_HEADING_UPS_TRACKING; ?></b>??<?php echo tep_draw_textbox_field('ups_track_num', '20', '18', '', $order->info['ups_track_num']); ?><a href="http://wwwapps.ups.com/WebTracking/processRequest?HTMLVersion=5.0&Requester=NES&AgreeToTermsAndConditions=yes&loc=en_US&tracknum=<?php echo $order->info['ups_track_num']; ?>" target="_blank"><?php echo $order->info['ups_track_num']; ?></a></td>

</tr>

<tr>

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>

</tr>

<tr>

<td class="main"><b><?php echo TABLE_HEADING_FEDEX_TRACKING; ?></b>??<?php echo tep_draw_textbox_field('fedex_track_num', '20', '18', '', $order->info['fedex_track_num']); ?><a href="http://www.fedex.com/cgi-bin/tracking?action=track&language=english&last_action=alttrack&ascend_header=1&cntry_code=us&initial=x&mps=y&tracknumbers=<?php echo $order->info['fedex_track_num']; ?>" target="_blank"><?php echo $order->info['fedex_track_num']; ?></a></td>

</tr>

<tr>

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>

</tr>

<tr>

<td class="main"><b><?php echo TABLE_HEADING_USPS_TRACKING; ?></b>??<?php echo tep_draw_textbox_field('usps_track_num', '24', '24', '', $order->info['usps_track_num']); ?><a href="http://trkcnfrm1.smi.usps.com/PTSInternetWeb/InterLabelInquiry.do?origTrackNum=<?php echo $order->info['usps_track_num']; ?>" target="_blank"><?php echo $order->info['usps_track_num']; ?></a></td>

That is so convenient from the admin side. I just love it. :thumbsup:

Link to comment
Share on other sites

Where in your admin/orders.php file are you placing this code? I would like to try it out myself.

Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Link to comment
Share on other sites

Nevermind found it. Is thier a way to clean it up and make it a button rather then a alpha-numeric link?

Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Link to comment
Share on other sites

But this also happens for my emails when I update the order status:

EMAIL_TEXT_SUBJECT_11EMAIL_TEXT_SUBJECT_2Pending[/b] is what the subject of the email is. I dont think there is an EMAIL_TEXT_SUBJECT_11...

 

I am also having this problem with order emails sent to the customer.

Link to comment
Share on other sites

Nevermind found it. Is thier a way to clean it up and make it a button rather then a alpha-numeric link?

Check the Contributions section for "Admin Side Package Tracking". I just uploaded a little add-on that will add Track button to the orders page inside admin. Screenshot is provided for a better understanding.

Link to comment
Share on other sites

great contribution my only issue is with the email confirmation I get

 

EMAIL_TEXT_TRACKING_HEADER

------------------------------------------------------

Package tracking numbers (click "invoice" link to track):

USPS: *******************

EMAIL_TEXT_TRACKING_NUMBER_2

 

EMAIL_TEXT_STATUS_HEADER

 

and would this contribution be hard to intergrate with edit orders contribution ?

I assume you would only need to edit edit_orders.php in the catalog/admin dir and in the language dir.

I use that mainly for updating orders.

 

Thanks!

Link to comment
Share on other sites

  • 1 month later...

Hi, i was wondering how hard it would be to alter this contrib so that it only uses royalmail for tracking.

 

Instead of 3 tracking numbers just have one. with a link pointing to this url: RoyalMail Track and trace

 

It would be a good idea for us UK people as we don't use ups or fedex.

 

Or has this already been done?

your thoughts please!!!!!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...