Jump to content

olsonsp4c

Members
  • Content count

    545
  • Joined

  • Last visited

Posts posted by olsonsp4c


  1. If you want the email sent successful header message to be green instead of red, just change the following in index_maintenance.php

     

    Find this:

    $messageStack->add('maintenance', EMAIL_SUCCESS);

     

    REPLACE with this:

     

    $messageStack->add('maintenance', EMAIL_SUCCESS, 'success');

     

    Thanks to Glen for the suggestion.

     

    Scott


  2. osC reCaptcha v1.4 is out: http://addons.oscommerce.com/info/6306

     

    This is a major restructuring.

     

    Since v1.3

    ----------

    * Added reCaptcha box formatting options A (non-integrated color scheme and placement) and B (integrated color scheme and placement)

    * Added instructions to add SSL security to reCaptcha

    * Changed language define to main english file

    * Added multi-language functionality

    * Added database entries to secure reCaptcha keys for security purposes

    * Fixed Customer Testimonials missing line

    * Added update instructions

    * Added additional screenshot

    * Restructured instructions for changes

     

    Thanks to SteveDallas for his helpful suggestions and code

     

    Let me know if I missed anything!

     

    Scott


  3. I will be releasing the v1.4 of osC reCaptcha tomorrow. Check here for the announcement. I want to especially thank Glen for his great ideas. All of them will be implemented in this version and there are a few small errors that are corrected in the instructions. This new version will drastically change how this is implemented, making it more secure, flexible, and more easily integrated into your store.

     

    Scott


  4. Scott, this may be a dumb question, but is this designed to populate the text box in admin if a tracking number has been added? I've double and triple checked my code and it's all there. I'm confused at this point.

     

    This is the code that populates the input boxes in admin/orders.php - look for "$order->info['xxxx_track_num'];" - it grabs the input from the db query:

     

    <!-- Package Tracking Plus BEGIN -->
      <tr>
    	<td><table border="0" cellspacing="0" cellpadding="2">
    	  <tr>
    		<td class="main"><b><?php echo TABLE_HEADING_USPS_TRACKING; ?></b></td>
    		<td class="main"><?php echo tep_draw_textbox_field('usps_track_num', '40', '40', '', $order->info['usps_track_num']); ?></td>
    		<td class="main"><a target="_blank" href="http://trkcnfrm1.smi.usps.com/PTSInternetWeb/InterLabelInquiry.do?origTrackNum=<?php echo $order->info['usps_track_num']; ?>"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    		<td class="main"><?php echo tep_draw_textbox_field('usps_track_num2', '40', '40', '', $order->info['usps_track_num2']); ?></td>
    		<td class="main"><a target="_blank" href="http://trkcnfrm1.smi.usps.com/PTSInternetWeb/InterLabelInquiry.do?origTrackNum=<?php echo $order->info['usps_track_num2']; ?>"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    	  </tr>
    	  <tr>
    		<td colspan="5"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
    	  </tr>
    	  <tr>
    		<td class="main"><b><?php echo TABLE_HEADING_UPS_TRACKING; ?></b></td>
    		<td class="main"><?php echo tep_draw_textbox_field('ups_track_num', '40', '40', '', $order->info['ups_track_num']); ?></td>
    		<td><a target="_blank" href="http://wwwapps.ups.com/etracking/tracking.cgi?InquiryNumber1=<?php echo $order->info['ups_track_num']; ?>&InquiryNumber2=&InquiryNumber3=&InquiryNumber4=&InquiryNumber5=&TypeOfInquiryNumber=T&UPS_HTML_Version=3.0&IATA=us&Lang=en&submit=Track+Package"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    		<td class="main"><?php echo tep_draw_textbox_field('ups_track_num2', '40', '40', '', $order->info['ups_track_num2']); ?></td>
    		<td><a target="_blank" href="http://wwwapps.ups.com/etracking/tracking.cgi?InquiryNumber1=<?php echo $order->info['ups_track_num2']; ?>&InquiryNumber2=&InquiryNumber3=&InquiryNumber4=&InquiryNumber5=&TypeOfInquiryNumber=T&UPS_HTML_Version=3.0&IATA=us&Lang=en&submit=Track+Package"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    	  </tr>
    	  <tr>
    		<td colspan="5"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
    	  </tr>
    	  <tr>
    		<td class="main"><b><?php echo TABLE_HEADING_FEDEX_TRACKING; ?></b></td>
    		<td class="main"><?php echo tep_draw_textbox_field('fedex_track_num', '40', '40', '', $order->info['fedex_track_num']); ?></td>
    		<td class="main"><a target="_blank" href="http://www.fedex.com/Tracking?tracknumbers=<?php echo $order->info['fedex_track_num']; ?>&action=track&language=english&cntry_code=us"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    		<td class="main"><?php echo tep_draw_textbox_field('fedex_track_num2', '40', '40', '', $order->info['fedex_track_num2']); ?></td>
    		<td class="main"><a target="_blank" href="http://www.fedex.com/Tracking?tracknumbers=<?php echo $order->info['fedex_track_num2']; ?>&action=track&language=english&cntry_code=us"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    	  </tr>
    	  <tr>
    		<td colspan="5"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
    	  </tr>
    	  <tr>
    		<td class="main"><b><?php echo TABLE_HEADING_DHL_TRACKING; ?></b></td>
    		<td class="main"><?php echo tep_draw_textbox_field('dhl_track_num', '40', '40', '', $order->info['dhl_track_num']); ?></td>
    		<td class="main"><a target="_blank" href="http://track.dhl-usa.com/atrknav.asp?ShipmentNumber=<?php echo $order->info['dhl_track_num']; ?>&action=track&language=english&cntry_code=us"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    		<td class="main"><?php echo tep_draw_textbox_field('dhl_track_num2', '40', '40', '', $order->info['dhl_track_num2']); ?></td>
    		<td class="main"><a target="_blank" href="http://track.dhl-usa.com/atrknav.asp?ShipmentNumber=<?php echo $order->info['dhl_track_num2']; ?>&action=track&language=english&cntry_code=us"><?php echo tep_image_button('button_track.gif', 'Track Package'); ?></a></td>
    	  </tr>
    	  <tr>
    		<td colspan="5"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>
    	  </tr>
    	</table></td>
      </tr>
    <!-- Package Tracking Plus END -->

     

    if this code is correct then you are missing the db query in admin/includes/classes/order.php

     

    	  $order_query = tep_db_query("select customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, usps_track_num, usps_track_num2, ups_track_num, ups_track_num2, fedex_track_num, fedex_track_num2, dhl_track_num, dhl_track_num2, currency, currency_value, date_purchased, orders_status, last_modified from " . TABLE_ORDERS . " where orders_id = '" . (int)$order_id . "'");

     

    or this in the same file:

     

    FIND this:
    
      $this->info = array('currency' => $order['currency'],
    					  'currency_value' => $order['currency_value'],
    					  'payment_method' => $order['payment_method'],
    					  'cc_type' => $order['cc_type'],
    					  'cc_owner' => $order['cc_owner'],
    					  'cc_number' => $order['cc_number'],
    					  'cc_expires' => $order['cc_expires'],
    					  'date_purchased' => $order['date_purchased'],
    					  'orders_status' => $order_status['orders_status_name'],
    					  'last_modified' => $order['last_modified'],
    					  'total' => strip_tags($order_total['text']),
    					  'shipping_method' => ((substr($shipping_method['title'], -1) == ':') ? substr(strip_tags($shipping_method['title']), 0, -1) : strip_tags($shipping_method['title'])));
    
    INSERT this ABOVE the last line:
    
    //Package Tracking Plus BEGIN
    					  'usps_track_num' => $order['usps_track_num'],
    					  'usps_track_num2' => $order['usps_track_num2'],
    					  'ups_track_num' => $order['ups_track_num'],
    					  'ups_track_num2' => $order['ups_track_num2'],
    					  'fedex_track_num' => $order['fedex_track_num'],
    					  'fedex_track_num2' => $order['fedex_track_num2'],
    					  'dhl_track_num' => $order['dhl_track_num'],
    					  'dhl_track_num2' => $order['dhl_track_num2'],
    //Package Tracking Plus END

     

    MAKE sure that EVERY line EXCEPT the last one ends with a "," (comma) while the LAST line ends with ");"

     

    It would be safest to have your last line still be:

     

    						  'shipping_method' => ((substr($shipping_method['title'], -1) == ':') ? substr(strip_tags($shipping_method['title']), 0, -1) : strip_tags($shipping_method['title'])));

     

    Scott


  5. i must be missing something - does this contrib work with OSCMax and BTS - what do i need to do to make it work

     

    any pointers would be apprecuiated

     

    i have version 3.62 of this contrib

     

    I don't know if this is possible easily, for sure it would take some serious hacking and I am not very familiar with either. I just installed a bunch of mods on CRE loaded for a client and it was a nightmare searching through the maze of code. Sorry I can't help...

     

    Scott


  6. I have the same problem with no image. I'm using Additional images contribution.

    Flash option works but always shows online status.

     

    Any suggestions?

    Thanks, Marios.

     

    Marios,

     

    i'm not familiar with that addon - my guess is that your going to have to mod the infobox to pull from the correct directory, the one specified in the install doc for additonal images, but it is just a guess.

     

    Scott


  7. Could you please post the solution to this, I am looking for the same question to be answered. I do not see any change to the product on the catalog side when i 0 the stock. Thanks

     

    Hello, there is not supposed to be any visible change in the catalog when stock is 0.

     

    When the stock is 0, this addon waits for you to change the stock to MORE than 0, then it notifies the customer that the product is in stock by email. It is all transparent. If you installed the mod that deletes the customer from the notification table, if you are that customer and you are logged in, the button on the product page will change from "Remove Notification" to a normal "Notification" button.

     

    Scott


  8. Think i found the error in response_handler.php - someone else verify please:

     

    Find this:

     

    	  for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
    // Stock Update - Joao Correia
    	if (STOCK_LIMITED == 'true') {
    	  if (DOWNLOAD_ENABLED == 'true') {
    		$stock_query_raw = "SELECT products_quantity, pad.products_attributes_filename 
    							FROM " . TABLE_PRODUCTS . " p
    							LEFT JOIN " . TABLE_PRODUCTS_ATTRIBUTES . " pa
    							 ON p.products_id=pa.products_id
    							LEFT JOIN " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . " pad
    							 ON pa.products_attributes_id=pad.products_attributes_id
    							WHERE p.products_id = '" . tep_get_prid($order->products[$i]['id']) . "'";
    // Will work with only one option for downloadable products
    // otherwise, we have to build the query dynamically with a loop
    		$products_attributes = @$order->products[$i]['attributes'];
    		if (is_array($products_attributes)) {
    		  $stock_query_raw .= " AND pa.options_id = '" . $products_attributes[0]['option_id'] . "' AND pa.options_values_id = '" . $products_attributes[0]['value_id'] . "'";
    		}
    		$stock_query = tep_db_query($stock_query_raw);
    	  } else {
    		$stock_query = tep_db_query("select products_quantity from " . TABLE_PRODUCTS . " where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    	  }
    	  if (tep_db_num_rows($stock_query) > 0) {
    		$stock_values = tep_db_fetch_array($stock_query);
    // do not decrement quantities if products_attributes_filename exists
    		if ((DOWNLOAD_ENABLED != 'true') || (!$stock_values['products_attributes_filename'])) {
    		  $stock_left = $stock_values['products_quantity'] - $order->products[$i]['qty'];
    		} else {
    		  $stock_left = $stock_values['products_quantity'];
    		}
    		tep_db_query("update " . TABLE_PRODUCTS . " set products_quantity = '" . $stock_left . "' where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    		if ( ($stock_left < 1) && (STOCK_ALLOW_CHECKOUT == 'false') ) {
    		  tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '0' where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    		}
    	  }
    	}

     

    Replace with this:

     

    	  for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
    // Stock Update - Joao Correia
    	if (STOCK_LIMITED == 'true') {
    	  if (DOWNLOAD_ENABLED == 'true') {
    		$stock_query_raw = "SELECT products_quantity, pad.products_attributes_filename 
    							FROM " . TABLE_PRODUCTS . " p
    							LEFT JOIN " . TABLE_PRODUCTS_ATTRIBUTES . " pa
    							 ON p.products_id=pa.products_id
    							LEFT JOIN " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . " pad
    							 ON pa.products_attributes_id=pad.products_attributes_id
    							WHERE p.products_id = '" . tep_get_prid($order->products[$i]['id']) . "'";
    // Will work with only one option for downloadable products
    // otherwise, we have to build the query dynamically with a loop
    		$products_attributes = @$order->products[$i]['attributes'];
    		if (is_array($products_attributes)) {
    		  $stock_query_raw .= " AND pa.options_id = '" . $products_attributes[0]['option_id'] . "' AND pa.options_values_id = '" . $products_attributes[0]['value_id'] . "'";
    		}
    		$stock_query = tep_db_query($stock_query_raw);
    	  } else {
    		$stock_query = tep_db_query("select products_quantity from " . TABLE_PRODUCTS . " where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    	  }
    	  if (tep_db_num_rows($stock_query) > 0) {
    		$stock_values = tep_db_fetch_array($stock_query);
    // do not decrement quantities if products_attributes_filename exists
    		if ((DOWNLOAD_ENABLED != 'true') || (!$stock_values['products_attributes_filename'])) {
    		  $stock_left = $stock_values['products_quantity'] - $order->products[$i]['qty'];
    		} else {
    		  $stock_left = $stock_values['products_quantity'];
    		}
    		tep_db_query("update " . TABLE_PRODUCTS . " set products_quantity = '" . $stock_left . "' where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    		if ( ($stock_left < 1) && (STOCK_ALLOW_CHECKOUT == 'false') ) {
    		  tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '0' where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
    		}
    	  }
    	}
     }

     

    Scott


  9. Guys, everything so far is working fine with this contribution on the customer end. The only problem I'm having is, once a tracking # is entered in admin and updated, the text box isn't populated with the tracking number after a page reload. This makes it difficult to know whether a tracking number has been entered.

     

    Please advise on where I might look to resolve this issue.

     

    Thanks, Frank

     

    Frank, it is most likely in admin/orders.php or in admin/includes/classes/order.php - double check your edits in these two files...

     

    Scott


  10. Hello,

     

    I installed this add-on (which is great, by the way) and was having problems with the javascript in my admin panel, so I removed that aspect of it. It was adding code to my configuration, so naow I just open a new browser window for my admin.php and can assist customers from there. Works for me...

     

    Anyway, I added the https stuff and javascript on the client.php file. Everything works great, but the client pop-up window does not say https://ayurvedayogashop.com/live_support/client.php, as I assumed it would. It is a regular http://... instead.

     

    Anything I missed there? :blush:

     

    Thanks,

     

    Yol

     

    give me until Monday and I'll get back with you.

     

    Scott


  11. Everything works fine except when I change to Maintenance store mode and I try to send an email box with a few valid email addresses, I have this message:

    "Your E-Mail Address does not appear to be valid - please make any necessary corrections."

     

    can sb tell me why?

     

    hi, i'll look into it and get back with you - might take a day or to, if you need, feel free to go into the index_maintenance.php page and remove the section that validates the email addresses and produces the error message, then it will work just fine.

     

    Scott


  12. Yeah, I cant find the code I deleted in my older backups. It pretty much was an older version of this methods contrib. It was in the code commented by // Methods 3.0

     

     

    Correct.

     

    Ok, so I narrowed it down, and it seems that any order placed that uses a shipping figure provided by the USPS module is not visible in the orders.php page.

    All my test orders placed using flat rate, table rate, or per item shipping modules show up just fine and normal. This leads me to believe that somewhere down the line some type of error/bug is introduced. Now, I may have missed a line of code somewhere, or it is interference with another contribution. I would like to reinstall the Methods contrib from the start, to unedited files.

     

    Looking at the installation.txt file in the 4.3.0 contrib package, would I follow the 6 step install directions, the 9 step ones, or both?

     

    Thanks again,

    --Martin--

     

    If you are upgrading from a pre 3.0 version of usps, use the second set of instructions. if you are upgrading from a version from 3.0.1 but prior to 4.3.0, then you should follow the set of instructions if you are first set of instructions and then skip down to STEP 8 on the second set of instructions... that's my take, it is a little confusing. My guess is that you might have followed the first set of instructions and were upgrading from a pre-3.0 version initially so missed the addition to the modules.php file.

     

    Scott


  13. Glen,

     

    thanks again - this week I'll add the features you have suggested and I'll publish a new tested version by Thanksgiving... I truly appreciate your suggestions as it is not often that I get input backed by solid code that helps improve the addon - I really appreciate it as that is what Open Source is all about.

     

    Scott


  14. Scott,

    I think the conflict I'm having with the status 2 setting in live support.php and the status image is with the On_the_fly Auto Thumbnailer 2.4 mod I have installed. I believe I read on the dayana phponline forum that someone had an issue with this at one time, but thought it was fixed in a later version. But the "no_image.jpg" that appears in the live support info box ( when set to status 2 in livesupport.php) is the default image with the on_the_fly thumbnailer mod. And it's being pulled from my "/images folder instead of my "phponline/images folder as it should. Until I figure out how to correct that I'm sticking with the status 1 flash image setting that works beautifully. I read recently that customers are more likely to use a live chat system than use a 800 toll free line you might have listed on your site. So, thanks again for the contribution and support thread.

     

    try this thumbnailer: http://addons.oscommerce.com/info/1484

    is use the version by ifunk and olaf

     

    Scott


  15. Actually I did. I followed the install directions in the file quite carefully. It seems I had some other code in there that was messing it up. I deleted it and now the edit feature works.

    The orders.php still isnt working though, so thats another thing for me to troubleshoot now.

     

    Thanks for the help!

    --Martin--

     

    Could you please post your changes, what you edited? it might help others who had the same issue...

    Also, do you mean that the order is placed, it shows up in the database, BUT it is not visible in ANY way in the admin->orders.php interface?

     

    Scott


  16. I just upgraded to 4.2.1 and while its nice it also created a few problems for me.

     

    The module installs just fine from the admin/modules.php page, however when I go to hit "edit" I get this error:

     

    Fatal error: Call to undefined function: tep_cfg_select_multioption() in /htdocs/catalog/admin/modules.php(212) : eval()'d code on line 1

     

    Searching around there appears to be no fix that I can find. I got around it by opening up the MySQL file and editing the individual options by hand, the long way. Very slow.

     

     

    Now, the biggest problem of them all is that admin/orders.php does not recognize that there are new orders there. The 3-4 test orders (and 2 live ones) that have gone through since I upgraded are in the SQL database but the admin/orders.php does not view them.

     

    Does anyone have any suggestions as to what may be the issue here?

     

    Thank you for your time,

    --Martin--

     

    You didn't complete the step where you were supposed to edit catalog/admin/includes/modules.php and add the following function:

     

    // USPS Methods 3.0
    // Alias function for Store configuration values in the Administration Tool
     function tep_cfg_select_multioption($select_array, $key_value, $key = '') {
    for ($i=0; $i<sizeof($select_array); $i++) {
      $name = (($key) ? 'configuration[' . $key . '][]' : 'configuration_value');
      $string .= '<br><input type="checkbox" name="' . $name . '" value="' . $select_array[$i] . '"';
      $key_values = explode( ", ", $key_value);
      if ( in_array($select_array[$i], $key_values) ) $string .= ' CHECKED';
      $string .= '> ' . $select_array[$i];
    }
    $string .= '<input type="hidden" name="' . $name . '" value="--none--">';
    return $string;
     }

     

    Scott


  17. Well, I must have a conflict somewhere. I renamed the online.jpg in my phponline/images folder as no_image.jpg. Doesn't show. Then I placed the renamed image in my "/images folder and it shows in my live support info box. Doesn't signal online/offline status of course, but it shows. Still not correct...

     

    you are welcome... glad to serve.

     

    Scott

×