Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

olsonsp4c

Pioneers
  • Posts

    545
  • Joined

  • Last visited

Posts posted by olsonsp4c

  1. Also, anyone aware of an option to do a zero weight shipping calc?

    Since I have tare weight and handling in my calcs, it will always add a minimal shipping charge at this point, which I do not want...on these items I will follow up orders with actually shipping costs and invoice them accordingly, major PITA and consumer of time.

     

    Any leads would be much appreciated....

     

    In the code there is a section which states that USPS does not accept 0 weight; however, you could mod that section of the code to accomplish what you want, I think. Here's the code that mods 0 weights to round up.

     

    // usps doesnt accept zero weight
      $shipping_weight = ($shipping_weight < 0.1 ? 0.1 : $shipping_weight);
      $shipping_pounds = floor ($shipping_weight);
      $shipping_ounces = round(16 * ($shipping_weight - floor($shipping_weight)));
      $this->_setWeight($shipping_pounds, $shipping_ounces);

     

    thanks for using this addon!

     

    Scott

  2. is there a way to use this only for orders under a set max weight? for example, i want to use a flat rate on all orders up to 25 lbs. beyond that weight, i don't want the flat rate to show up as an option. as it is now, it just shows the larger box price beyond the max weight.

     

    Ted,

     

    This should not be difficult to add, it would mean 1 additional database field and a compare statement... good idea - i'll work on it.

     

    Scott

  3. First off, Great contribution. Thank you.

     

    Slight issue with a clean 2.2 rc2a install and this contribution loaded

     

    Customers are having issues with paypal payments. Once they choose paypal and continue, they are taken to a login screen. After logging in they see a screen that wants them to review information, ie, funds source, address and contact info, then a continue button. The page has an error:

     

    the error on the page says:

     

    Fatal error: Class 'httpClient' not found in /home/XXXXXX/public_html/catalog/includes/modules/shipping/usps.php on line 269

     

    I removed this contribution and loaded a flat rate shipping option - The error goes away and the transaction is successful.

    Any thoughts?

    Thanks in advance.

    -billy

     

    what version are you using?

     

    thanks!

     

    Scott

  4. We use both of the flat rate boxes + the $4.60 flat rate envelope. + international rates.

     

    Is there a way to add the $4.60 envelope to this.

     

    Also, is there a way to add the international flat rate prices as well?

     

    Canada & Mexico

    $29.95 for the large flat rate box

    $23.00 for the regular flat rate box

    $9.00 for the flat rate envelope

    Other countries

     

    $49.95 for the large flat rate box

    $37.00 for the regular flat rate box

    $11.00 for the envelope

     

    I am still new to php. Is this something that I can edit into the two files or do you plan on adding this later?

    Thank you for this great addon! I have been wanting this for so long...

    Brad

     

    P.S

    Is there anyone who has found a contribution to add individual shipping prices per item in the create new listing/edit listing form. I need to add the shipping rate per item to all my listings like in ebay. Some of our items take 3 regular flat rate boxes and we need the shipping for that item to be $26.85, etc.

     

    if you wanted the envelope vs the boxes determined by weight it would not be difficult to add. Also, international would not be difficult to add, I'm planning on adding these things in the next month or so if you can wait :)

    also, here is the addon you are looking for: http://addons.oscommerce.com/info/4674

    Scott

  5. For now anyway I am just not accepting PayPal for payment of orders. That seems to make life a lot simpler.

     

    I use an older version of the Paypal IPN, version 1.4 by windfif and it works very will and does pass things along properly. You might try that version.

     

    Scott

  6. the file is admin/orders.php

    and is the same problem as post#40 from kloienyc

    I'm having the exact same error and offending line of code

     

    error

    Parse error: parse error, unexpected T_CASE in

     

    offending line of code

    case 'deleteconfirm':

     

    The issue, I believe, was copying these two line into admin/orders.php that is not a part of the edit but is only there for placement (creates and extra } and messes with the if statements):

     

    		  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;
    	}

     

    Scott

  7. To make it clear what is happening.

     

    This is what the transaction should be:

    Sub-Total: $56.95

    United States Postal Service (1 x 0.52lbs) (First Class Mail (Estimated: 2 - 5 Days)): $2.32

    USPS Shipping Insurance: $2.05

    State Sales Tax: $3.70

    Total: $65.02

     

     

    At PayPal

    Subtotal: $60.65

    Shipping and Handling: $2.32

    Tax: (6.500% in Minnesota): $3.94

    Total: $66.91 USD

    It appears the sales tax is getting added to the cost of merchandise and the insurance charge does not get added to PayPal total.

     

    Thanks for the clarity - it seems that it might be getting passed to Paypal actually... well, it might be - adding the insurance to the sub-total and then passing it on to Paypal, but there is extra coming from somewhere that is unaccounted for... also, have you looked at this:

     

    QUOTE(Aldebaran @ Dec 13 2007, 12:58 AM) *

    Hi,

    Running osCommerce 2.2-MS2 and installed the PayPal IPN module.

     

    Get no errors, but if you enter a discount code, it is NOT getting passed to PayPal. PayPal uses the full amount and charges the full amount to customer, whether they have a credit card or are using a PayPal account.

     

    I have the module set to aggregate, which others have said solved this issue, but this doesn't solve issue.

     

    When you go back to store, the order shows the discounted amount and so does the email sent to customer - so there's a big mismatch.

     

    All suggestions welcome rolleyes.gif

     

    Everything else appears to work normally.

     

    Jill

     

     

    I have the same problems as you. discount and insurance do not pass to paypal. I tried the following way. I am not sure it will solve the problem until my customer buy one product. do you set up any thing in paypal-->profile-->shipping calculation???

     

    1.) make sure you have your shipping mods. set up like you want in os.

    2.)Log into your paypal account.

    3.)Click on "profile"

    4.)Click on "Set Up Shipping Calculations"

    5.)Make sure there is NOTHING set up here.

     

    thanks!

     

    Scott

  8. To make it clear what is happening.

     

    This is what the transaction should be:

    Sub-Total: $56.95

    United States Postal Service (1 x 0.52lbs) (First Class Mail (Estimated: 2 - 5 Days)): $2.32

    USPS Shipping Insurance: $2.05

    State Sales Tax: $3.70

    Total: $65.02

     

     

    At PayPal

    Subtotal: $60.65

    Shipping and Handling: $2.32

    Tax: (6.500% in Minnesota): $3.94

    Total: $66.91 USD

    It appears the sales tax is getting added to the cost of merchandise and the insurance charge does not get added to PayPal total.

     

    thanks for the update... i am out all day today, so I take a peek tomorrow.

     

    if you need to, temporarily disable the mod so you don't lose money.

     

    Scott

  9. I see you're a fellow night owl, its almost 3am here. I made the change and now get the drop down for tax class, however still no sales tax in the shipping calculation. I tried it with both versions of the checkout_confirmation mod.

     

    A few more edits and let me know what happens:

     

    FIND this:

     

    	  $this->enabled = MODULE_OT_USPSINSURANCE_STATUS;

     

    ADD this AFTER:

     

    	  $this->tax_class = MODULE_OT_USPSINSURANCE_TAX_CLASS;

     

    FIND this:

     

    		$this->output[] = array('title' => $this->title . ':',
    							'text' => $currencies->format($insurance, true, $order->info['currency'], $order->info['currency_value']),
    							'value' => ($insurance * $shipping_num_boxes));

     

    ADD this AFTER:

     

    		if ($this->tax_class > 0) {
    	  $this->output['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']);
    	}

     

    Let me know... i'm off to bed, hope this works...

     

    Scott

  10. I just issued version 1.1 of this contribution:

     

    Changes since v1.0

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

    * Corrected the colspan to "3" instead of "4" in the second half of checkout_payment.php

    * Corrected the table alignment issues in checkout_payment.php

    * Added BEGIN and END comments to the stylesheet

    * Added the missing Tax Class database entry and corresponding code edits

    * Added update instructions

     

    http://addons.oscommerce.com/info/5782

     

    Scott

  11. I see you're a fellow night owl, its almost 3am here. I made the change and now get the drop down for tax class, however still no sales tax in the shipping calculation. I tried it with both versions of the checkout_confirmation mod.

     

    Did you update the sort order so that shipping insurance is numbered 1 higher than tax?

     

    could you clarify on the "both" versions of the checkout_confirmation.php file? I have not updated anything in this file (just the 1 edit - 1 added line)...

     

    Scott

  12. Joseph,

     

    You are correct. Could you let me know which Paypal Module and version you are using?

     

    One quick suggestion is to try making the same edit you made in checkout_confirmation.php to your Paypal file.

     

    Scott

  13. Ok now I get a space in admin where I assume the new drop down should be but there is nothing in that area.

     

    Kimm,

     

    I'm making mistakes... i apologize, it's late here in Portland.

     

    the changes should have read this:

     

    FIND this:

     

     

    	  return array('MODULE_OT_USPSINSURANCE_STATUS', 'MODULE_OT_USPSINSURANCE_INSURE_TAX', 'MODULE_OT_USPSINSURANCE_CHOICE', 'MODULE_OT_USPSINSURANCE_SORT_ORDER', 'MODULE_OT_USPS_INS1', 'MODULE_OT_USPS_INS2', 'MODULE_OT_USPS_INS3','MODULE_OT_USPS_INS4', 'MODULE_OT_USPS_INS5', 'MODULE_OT_USPS_INS6', 'MODULE_OT_USPS_INS7', 'MODULE_OT_USPS_INS8', 'MODULE_OT_USPS_INS9', 'MODULE_OT_USPS_INS10');

     

    REPLACE with this:

     

     

    	  return array('MODULE_OT_USPSINSURANCE_STATUS', 'MODULE_OT_USPSINSURANCE_INSURE_TAX', 'MODULE_OT_USPSINSURANCE_TAX_CLASS', 'MODULE_OT_USPSINSURANCE_CHOICE', 'MODULE_OT_USPSINSURANCE_SORT_ORDER', 'MODULE_OT_USPS_INS1', 'MODULE_OT_USPS_INS2', 'MODULE_OT_USPS_INS3','MODULE_OT_USPS_INS4', 'MODULE_OT_USPS_INS5', 'MODULE_OT_USPS_INS6', 'MODULE_OT_USPS_INS7', 'MODULE_OT_USPS_INS8', 'MODULE_OT_USPS_INS9', 'MODULE_OT_USPS_INS10');

     

    FIND this:

     

     

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_USPSFLAT_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

     

    REPLACE with this:

     

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_OT_USPSINSURANCE_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

     

     

    for you at this point it just means changing MODULE_OT_USPSFLAT_TAX_CLASS to MODULE_OT_USPSINSURANCE_TAX_CLASS in the 1st REPLACE

     

    Scott

  14. Ok I made the change in the file and can see the changed in the database but I don't get a drop down box in admin for the tax class.

     

    oops, i forgot another...

     

    1. Remove the module

    2. make these changes

     

     

    FIND this:

     

    	  return array('MODULE_OT_USPSINSURANCE_STATUS', 'MODULE_OT_USPSINSURANCE_INSURE_TAX', 'MODULE_OT_USPSINSURANCE_CHOICE', 'MODULE_OT_USPSINSURANCE_SORT_ORDER', 'MODULE_OT_USPS_INS1', 'MODULE_OT_USPS_INS2', 'MODULE_OT_USPS_INS3','MODULE_OT_USPS_INS4', 'MODULE_OT_USPS_INS5', 'MODULE_OT_USPS_INS6', 'MODULE_OT_USPS_INS7', 'MODULE_OT_USPS_INS8', 'MODULE_OT_USPS_INS9', 'MODULE_OT_USPS_INS10');

     

    REPLACE with this:

     

    	  return array('MODULE_OT_USPSINSURANCE_STATUS', 'MODULE_OT_USPSINSURANCE_INSURE_TAX', 'MODULE_OT_USPSFLAT_TAX_CLASS', 'MODULE_OT_USPSINSURANCE_CHOICE', 'MODULE_OT_USPSINSURANCE_SORT_ORDER', 'MODULE_OT_USPS_INS1', 'MODULE_OT_USPS_INS2', 'MODULE_OT_USPS_INS3','MODULE_OT_USPS_INS4', 'MODULE_OT_USPS_INS5', 'MODULE_OT_USPS_INS6', 'MODULE_OT_USPS_INS7', 'MODULE_OT_USPS_INS8', 'MODULE_OT_USPS_INS9', 'MODULE_OT_USPS_INS10');

     

    FIND this:

     

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_USPSFLAT_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

     

    REPLACE with this:

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_OT_USPSINSURANCE_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

     

    3. Re-install and choose options...

     

    Hopefully it works! I made these changes on my test store and got the dropdown box... let me know!

     

    :)

     

    Scott

  15. I guess that wasn't the problem. Made the change and still not sales tax calculated on shipping insurance. There is no place on the admin side when setting up the insurance to identify what tax class to use. Should there be? Maybe I did something wrong during the install.

     

    That is the issue Kimm... this is the adjustment - i will update it in the next release - sorry about that:

     

    1. Remove the order total module

    2. Open includes/modules/order_total/ot_uspsinsurance.php

     

    FIND this:

     

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Insure Tax', 'MODULE_OT_USPSINSURANCE_INSURE_TAX', 'True', 'Insure tax on packages shipped by USPS?', '6', '2', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())");

     

    AFTER add this:

     

    	  tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_USPSFLAT_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())");

     

    3. Re-install

    4. Make the sort order appropriate and choose options

     

    it should work :)

     

    Scott

  16. :-) Now, I see it... (In the e-mail) as for what my prior question was about... :thumbsup:

     

    Houston!! The Eagle has landed ~~ I can flow thru an order, of a fresh install of OSC (osCommerce Online Merchant v2.2 RC2a.) w/no other mods involved in it yet. To me, taking care of the background logistics was a "Priority 1" before continuing...and I thank-you for your relentless efforts on this mod.

     

    Does it work?...<laugh>... I don't know yet...lol.. But I have much faith!!

     

    I want to thank-you very much also for the fine documentation on this Scott, (except for the couple of questions I did have...and thx again for the answers thru the intall) as when i first PM'd you about this...I explained some about me. Back in the 80's when I was coding...my development of my C code, my comments would outrank the code 4-5x during development..

     

    Remember, that's when a box w/ 4 meg-of-ram on board was a "super computer" :lol:

     

    Now that it is installed, and I can "see" in the admin where/what etc...to enter...

     

    I do have a couple of "side questions"...that I'd like to ask about overall flow-vs-function...and if you don't mind me sending in a PM...instead of cluttering a support thread of yours for my questions.....if you have time.

     

    Thx again brother!! You'll be getting a donation from me on this one...

     

    Jim

     

    PS... Amy ??.. You never posted again, and I hope you didn't get flusterd and say " to heck with it "... If you need help, I'll be more than happy to also help you get as far as I did..and answer anything I can involved with this contrib so far.

     

    Feel free to PM me or to email me. If you'd like to make a donation, I could give you my Paypal account there... Thanks! Glad the install is completed.

     

    Scott

  17. I guess that wasn't the problem. Made the change and still not sales tax calculated on shipping insurance. There is no place on the admin side when setting up the insurance to identify what tax class to use. Should there be? Maybe I did something wrong during the install.

     

    OK, change the code back to the way it was - let me check into your question and get back with you :)

     

    Scott

  18. Great and thx... (sorry) Call me a pinhead on that one... It's 10am here, been back and forth on this an adding items to the cart...and 2 pots of coffee since 3:45 making my eyes flutter some..

     

    OK, I did Part 1 step 6..

     

    Now ??

    And REPLACE with this (customize): ( Your code says > If necessary, you may update your order directly by following the link above (login required).

     

    And the other has nothing like that...so... Does this have something to do with Order Edit contrib?

     

    Just checking...and I'm past half way thru your install file... I hope I get it done this year...<just kidding while I am laughing>

     

    And each step, I am uploading and making sure my cart is still somewhat intact...also...except for total checkout.

     

    Jim

     

    it is a part of the addon (not order editor)

    Scott

  19. Not a problem, and for this one I am doing...I don't feel I'll need it one way or the other...

     

    But, now here is a "dumb one"

     

    I decided to just continue and also read on. I am at Step 6

    >define('TABLE_HEADING_TOTAL_INCLUDING_TAX', 'Total (inc)');

     

    Now, I have a fresh install ( well, it was a few days ago...lol And

    > OPEN catalog/admin/includes/languages/english/orders.php

     

    Has the following... DUPLICATE entries from what I can see?

     

    define('TABLE_HEADING_PRICE_EXCLUDING_TAX', 'Price (ex)');

    define('TABLE_HEADING_PRICE_INCLUDING_TAX', 'Price (inc)');

    define('TABLE_HEADING_TOTAL_EXCLUDING_TAX', 'Total (ex)');

    define('TABLE_HEADING_TOTAL_INCLUDING_TAX', 'Total (inc)');

    Now, You've been into this cart much longer than I have...and me... I'd delete the dups, but I'm not sure if they're needed..

     

    And I really dislike bothering anyone on a Sunday...but I have to post...when I have time...

     

    Jim

     

    PS...Also, for some reason, I am not getting notifications e-mailed of your posts at all, even though I selected it on my first post, but I did get notified when Irin made a post... That, I can't figure out either...as it says:

     

    You are currently receiving email notification of replies

     

    All four lines are necessary and if you look carefully, all four lines are actually different. You insert the line after the last of the four.

     

    Scott

  20. I hadn't run across "Order Editor" as of yet, but went and looked at the contrib for it, and see that it presently sits at a version of: 5.0.61.

     

    So this raises a question I need to ask please.

     

    IF I continue, should I just use OE2.7.4 ? Or will this (5.0.61) be incompatible with what I am doing (installing your contrib) in the future?

     

    Thx again, and sorry for the questions.... ( I have no problem popping of a donation Scott, I consider at my point of what I am doing...that getting your mod to function...is more critical for clients at my stage of my catalog.

     

    Again, thx!!

     

    Jim

     

    Jim,

     

    You don't need to install OE 2.7.4; however, it is an option for you if you desire, the instructions are there for integration. Also, I recognize that OE is at 5.0.61 at this point, but I stopped upgrading it at 2.7.4 into my store because it's changed so much and I don't need the extra functionality (at this point). Also, I didn't want to figure out new integration instructions for OE :)

     

    Scott

  21. (Adding information for my PayPal problem posting above.)

     

    The variable for insurance needs to be added to the /ext/ipn.php as it is for shipping below in ipn.php. Or, shipping and insurance could be added together on the order_confirmation page and then the variable "shipping" would be fine.

    Would someone write the code for either of those?

    [sat Mar 15 17:13:10 2008] [error] PP TEST received POST variable: shipping : 1.98

     

    some paypal modules need the following fix... if you install this contribution and the shipping insurance is not included in your paypal totals, TRY making the changes outlined below.

     

    You will need to MOVE the lines that you are instructed to insert into checkout_process.php so that the following three lines (not counting blanks):

     

    require(DIR_WS_CLASSES . 'order_total.php');

    $order_total_modules = new order_total;

     

    $order_totals = $order_total_modules->process();

     

    are just ABOVE the added part instead of below it and these 2 lines:

     

    // load the before_process function from the payment modules

    $payment_modules->before_process();

     

    are JUST BELOW it

     

    SO IT LOOKS LIKE THIS:

    ========================================

    require(DIR_WS_CLASSES . 'order.php');

    $order = new order;

    require(DIR_WS_CLASSES . 'order_total.php');

    $order_total_modules = new order_total;

     

    $order_totals = $order_total_modules->process();

     

    Try this and let me know if it helps...

     

    Scott

  22. Hey Scott,

     

    I think I may have found the reason that tax is not cal

    culated on the shipping insurance. I have CCGV(trad) loaded and I found the following code in checkout_confirmation:

    $payment_modules->update_status();

     

    $order_total_modules = new order_total;// CCGV

    $order_total_modules->collect_posts();// CCGV

    $order_total_modules->pre_confirmation_check();// CCGV

     

    // Line edited for CCGV

    // if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {

    if ( (is_array($payment_modules->modules)) && (sizeof($payment_modules->modules) > 1) && (!is_object($$payment)) && (!$credit_covers) ) {

    tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));

    }

     

    if (is_array($payment_modules->modules)) {

    $payment_modules->pre_confirmation_check();

    }

     

    // load the selected shipping module

    require(DIR_WS_CLASSES . 'shipping.php');

    $shipping_modules = new shipping($shipping);

    $_SESSION['choose_insurance'] = $_POST[choose_insurance]; //USPS shipping insurance

    //Lines below repositioned for CCGV

    // require(DIR_WS_CLASSES . 'order_total.php');

    // $order_total_modules = new order_total;

     

    It appears that the repositioned lines keep the shipping insurance from getting added into the order total. Any suggestions on how to fix this? I am a php dummy.

     

    TIA

    Kim

     

    Kim,

     

    try reposition the shipping lines to right before: $order_total_modules = new order_total;// CCGV

     

    let me know what happens...

     

    Scott

×
×
  • Create New...