Guest Posted February 9, 2012 Share Posted February 9, 2012 Yeah, my web server was down. It's a host issue and the reason I'll be changing hosts soon. If you want to test it, then set up a test site and install the thing. Don't take the generosity of others for granted. The editing restrictions are foolish. Care to elaborate? WHAT editing restrictions? Quote Link to comment Share on other sites More sharing options...
Guest Posted February 9, 2012 Share Posted February 9, 2012 @@pederb I found what you were talking about. Change this in the usps.php file: 'shownString' => $shownString, 'customerString' => $customerString); to this: 'shownString' => (string)$shownString, 'customerString' => (string)$customerString); I'll add that as part of my next update. Quote Link to comment Share on other sites More sharing options...
Dennisra Posted February 9, 2012 Share Posted February 9, 2012 Yeah, my web server was down. It's a host issue and the reason I'll be changing hosts soon. If you want to test it, then set up a test site and install the thing. Don't take the generosity of others for granted. The editing restrictions are foolish. Care to elaborate? WHAT editing restrictions? The ability to edit my post on this forum. Quote Link to comment Share on other sites More sharing options...
Guest Posted February 10, 2012 Share Posted February 10, 2012 The ability to edit my post on this forum. LOL, yup, I sort of put that together when I tried to edit something later and couldn't. It was a light bulb moment. Anyone interested in having the customer be able to upgrade their shipping by adding extra services (like insurance, signature confirmation, etc...)? I've got it written, but whether I upload it depends on the demand. Quote Link to comment Share on other sites More sharing options...
Dennisra Posted February 10, 2012 Share Posted February 10, 2012 I am definately interested in that. Can I PM you about having you install this for me in my osCommerce 2.2-MS2? Quote Link to comment Share on other sites More sharing options...
Guest Posted February 10, 2012 Share Posted February 10, 2012 Yes, you can. It was written specifically for 2.3.1 to work with features that aren't available in 2.2. But, those features could be added to 2.2 to make it work. The mod itself will work for calculating shipping, but the displays won't show in 2.2. Have you seen it in action on the test site yet? I've turned off the single page checkout for now, so you can see it in a normal checkout. It's at http://www.fulluvscents.com/catalog The straight link goes to my regular site, which I have down for now. Quote Link to comment Share on other sites More sharing options...
wkdwich Posted February 11, 2012 Share Posted February 11, 2012 Jetta.. PM'd you earlier.. think you can ignore that.. For everyones clarification, I run oscMAX 2.0.25 and when I get this installed and running I will report back. In my admin/includes/functions/general.php I see: function tep_sanitize_string($string) { $string = ereg_replace(' +', ' ', $string); return preg_replace("/[<>]/", '_', $string); } and // 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++) { $search = array(' reg', ' trade'); $replace = array('<sup>®</sup>', '<sup>™</sup>'); $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 .= '> ' . str_replace($search, $replace,$select_array[$i]); } $string .= '<input type="hidden" name="' . $name . '" value="--none--">'; return $string; } // USPS Methods. Added by Greg Deeth from what I am reading both need to be removed??? Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2012 Share Posted February 11, 2012 Yes, you can remove anything from your includes/functions/general.php AND your admin/includes/functions/general.php that refers to the old usps mod. If using UPS XML, I think the multioption function needs to stay for that, but not for this mod. tep_sanitize_string must have come from one of the versions after my 5.2.2, but if it's usps related, then it is not needed for this mod either. Quote Link to comment Share on other sites More sharing options...
wkdwich Posted February 11, 2012 Share Posted February 11, 2012 OK thanks.. I'll give it a go later.. Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
wkdwich Posted February 11, 2012 Share Posted February 11, 2012 Jetta, the only other references I found was the round up functions by Greg Deeth.. leave or remove them also? Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2012 Share Posted February 11, 2012 (edited) remove them. Most of the stuff isn't going to hurt anything, but I'm personally weird about removing stuff that isn't used. Edited February 11, 2012 by fulluvscents Quote Link to comment Share on other sites More sharing options...
wkdwich Posted February 12, 2012 Share Posted February 12, 2012 OK done.. removed all refereneces in all files for old USPS and any functions by Greg Deeth.. the only USPS reference that remained was: catalog/admin/includes/functions/general.php: // return short version on UPS and USPS $short_shipping_end= strpos($check_order['title'], ''); $short_shipping= substr($check_order['title'], 1, $short_shipping_end); return $short_shipping; files that got altered: catalog/checkout_shipping.php (on a oscv2.31) catalog/includes/sapplication_top.php catalog/includes/functions/general.php catalog/admin/modules.php catalog/admin/includes/functions/general.php osc admin copy the current settings for the USPS module uninstall module uploaded the above files upload the NEW files from the USPS Rate V4 Intl Rate V2 - v.1.7 zip file osc admin install module set up module I had a little bit of a time fooling with the settings, but I got it now.. I am a little dissapointed to NOT see the check boxes: Display OptionsSelect display options Display weight Display transit time Display insurance I don't like displaying the total weight of the package.. is that difficult to edit out of there??? Dissapointed (not less so..) to not see the transit time You did a really nice job on this :) Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Guest Posted February 12, 2012 Share Posted February 12, 2012 Yes, it was designed a bit differently from older versions. The weight is easy to edit out. Find this line: 'module' => $this->title . ' ' . $this->pounds . ' lbs, ' . $this->ounces . ' oz', Change it to this: 'module' => $this->title, Insurance and any extra services are not displayed as they used to be. They are now displayed as part of the breakdown of the total cost, if you choose to include it and show it to the customer. There is no admin defined insurance. This only returns USPS insurance rates, since it is a USPS mod. If you want to charge for non-usps insurance, then bundle it into your handling fees. If you want to insure in excess of USPS limits, you'll need a customized mod, or again, bundle that into handling. I didn't make provision for transit time in this mod (mostly because transit time is a completely different API than rates). I caught that after I finished it, and may decide to add that in later. But, I have things I need to do for myself before I come back to this. The biggest intent with this was to simplify and remove any excessive options while taking full advantage of the USPS rates API. I may add the transit API as an ADD ON to the USPS mod, rather than part of a new version. NOTE that I did add an "ADD ON" to block certain methods by product. It is a necessity for me and may prove itself to be useful for others as well. Quote Link to comment Share on other sites More sharing options...
♥altoid Posted February 12, 2012 Share Posted February 12, 2012 NOTE that I did add an "ADD ON" to block certain methods by product. It is a necessity for me and may prove itself to be useful for others as well. Hi there I have been following this and this latest option caught my attention. I have some drop ship products where my drop shipper charges a flat fee for shipping. So, with this I could disable all other USPS shipping methods for those products, resulting in the customer seeing the flat fee only on my drop ship type products? Thanks Quote I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can. I remember what it was like when I first started with osC. It can be overwhelming. However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc. There are several good pros here on osCommerce. Look around, you'll figure out who they are. Link to comment Share on other sites More sharing options...
wkdwich Posted February 12, 2012 Share Posted February 12, 2012 Thanks Jetta that did the trick on removing the weight from the shipping page.. Totally understand your reasoning on the options.. I also would like to see the addon for blocking by item.. I also do a good amount of drop shipping Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Guest Posted February 13, 2012 Share Posted February 13, 2012 Hi there I have been following this and this latest option caught my attention. I have some drop ship products where my drop shipper charges a flat fee for shipping. So, with this I could disable all other USPS shipping methods for those products, resulting in the customer seeing the flat fee only on my drop ship type products? Yes, if you drop ship and want to apply a flat fee, then you'll be able to block usps as an option. After you install it, just open the product editing page, click on restrict usps methods (which will drop down your list of methods) and check ALL the checkboxes. Sorry, I don't have a screenshot. It would probably help. This only applies to this particular USPS mod, so if you offer other shipping options, it won't block those. Quote Link to comment Share on other sites More sharing options...
♥altoid Posted February 13, 2012 Share Posted February 13, 2012 Yes, if you drop ship and want to apply a flat fee, then you'll be able to block usps as an option. After you install it, just open the product editing page, click on restrict usps methods (which will drop down your list of methods) and check ALL the checkboxes. Sorry, I don't have a screenshot. It would probably help. This only applies to this particular USPS mod, so if you offer other shipping options, it won't block those. Excellent and thanks very much. I have the older USPS mod currently installed (the one you helped us get that running again last year after USPS changed something), but will be removing that in favor of your current USPS mod. Again, thank you. Quote I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can. I remember what it was like when I first started with osC. It can be overwhelming. However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc. There are several good pros here on osCommerce. Look around, you'll figure out who they are. Link to comment Share on other sites More sharing options...
adanob Posted February 15, 2012 Share Posted February 15, 2012 This may be a simple fix but I can not seem to figure it out. Any help would be appreciated. Fatal error: Call to undefined function tep_get_version() in ......../html/NewShop/catalog/admin/includes/header.php on line 20 Why am I getting this? My Admin screen does not show. Quote Link to comment Share on other sites More sharing options...
wkdwich Posted February 15, 2012 Share Posted February 15, 2012 I highly suggest you use a compare program and compare the files from the contribution to the files you uploaded. Chances are you missed or mis-placed an edit if you did it by hand or uloaded something in the wrong place.. I did an upgrade for a client today running osc2.3.1 and there was some stuff missing.. added it and bingo everything was fine. Find the error, reupload everything and try again Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Guest Posted February 15, 2012 Share Posted February 15, 2012 That means either your function is missing or your file that defines the functions is missing. It should be found in admin/includes/functions/general.php - it's the first function in that file. Either restore a backup and start over, or download a fresh version of osc, and replace the file, or compare your file with the stock file to see what changes have been made and go from there. I have no idea what else you have installed, so I don't know what your file should look like. Quote Link to comment Share on other sites More sharing options...
♥altoid Posted February 17, 2012 Share Posted February 17, 2012 Jetta, working on installing this. Instructions say for a 2.3.1 shop: admin/modules.php*********************************************** Find or in osc 2.3.1: if (tep_not_null($action)) { switch ($action) { case 'save': reset($HTTP_POST_VARS['configuration']); while (list($key, $value) = each($HTTP_POST_VARS['configuration'])) { Insert After: // USPS START if( is_array( $value ) ) $value = implode( ', ', $value); // USPS END But a file compare shows different results: My file: each($HTTP_POST_VARS['configuration'])) { if( is_array( $value ) ){ $value = implode( ", ", $value); $value = ereg_replace (", --none--", "", $value); } tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . $value . "' where configuration_key = '" . $key . "'"); Compare File: each($HTTP_POST_VARS['configuration'])) { // USPS START if( is_array( $value ) ) $value = implode( ', ', $value); // USPS END tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . $value . "' where configuration_key = '" . $key . "'"); I presume I want the results as per the file provided for comparison removing: $value = ereg_replace (", --none--", "", $value); } As well as remove the associated bracket in the line above. Do I have that correct? Thanks Quote I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can. I remember what it was like when I first started with osC. It can be overwhelming. However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc. There are several good pros here on osCommerce. Look around, you'll figure out who they are. Link to comment Share on other sites More sharing options...
wkdwich Posted February 17, 2012 Share Posted February 17, 2012 Steve use a compare tool like Beyond Compare and you can really see where everything goes and whats needed.. Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
♥altoid Posted February 17, 2012 Share Posted February 17, 2012 Steve use a compare tool like Beyond Compare and you can really see where everything goes and whats needed.. Debbie thanks for responding. I did the compare and that's what brought the matter to my attention, wondering which way to go. Directions or file compare result. I'll go with what the file compare and see what happens. Thanks Quote I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can. I remember what it was like when I first started with osC. It can be overwhelming. However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc. There are several good pros here on osCommerce. Look around, you'll figure out who they are. Link to comment Share on other sites More sharing options...
Guest Posted February 17, 2012 Share Posted February 17, 2012 @@altoid As long as you don't have anything else that the modules.php file is using, replace it with the new instructions. Those were old USPS instructions and can be removed. This is what it should be now: each($HTTP_POST_VARS['configuration'])) { // USPS START if( is_array( $value ) ) $value = implode( ', ', $value); // USPS END tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . $value . "' where configuration_key = '" . $key . "'"); Quote Link to comment Share on other sites More sharing options...
wkdwich Posted February 17, 2012 Share Posted February 17, 2012 Jetta did I thank you for a fine job?? Everything is running nice and smooth now on my stores (oscMax 2.0.25) and a clients shop (osc 2.3.1) Quote Debbie DFranklin County, VA "Moonshine Capitol of the World"osCmax Mobile Template oscmaxtemplates.com Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.