Jump to content
FantasyArt

Adding another shipping module option.

Recommended Posts

I am looking for a new solution to adding a fixed shipping setting for a select few of the many items we have in our OsCommerce Store.

 

We have a number of our items that have a fixed postage cost of $16.50. These items are new products to our store and are yet to be made public as we can't do that until we are able to find this solution.

 

All of our other products shipping is handled by the Ozpost MultiQuote and I would like to be able to only show the fixed postage cost for the select items mentioned above.

 

This would work in the following situations:

 

Option 1: Item A is posted at $16.50 when placed in the cart by itself.

 

Option 2: Item A & B are posted at $16.50 plus what Ozpost MultiQuote calculates item B postage cost to be when placed in cart together.

 

Option 3: Item B is posted at whatever Ozpost MultiQuote calculates the postage cost to be when placed in the cart by itself.

 

If this is possible could someone help me work it out please or if there is already a module that I could use please point me in the right direction.

 

Any help will be greatly appreciated. We use Flat Rate Shipping, edited to be pickup option & Ozpost MultiQuote as our Postage Options on our Store. We also use Paypal Website Payments Standard & Bank Transfer or Deposit for or Payment options.

Share this post


Link to post
Share on other sites

If this is possible could someone help me work it out please or if there is already a module that I could use please point me in the right direction.

 

It's code. anything is possible.

 

The real question is how good are your coding skills?

 

Step#1. Ensure you are using the latest ozpost client V3.5.x or later.

Step#2. Set the products weight for the items needing special treatment to be zero.

Step#3. Configure the ozpost module to ignore products with zero weights.

(That's half of the solution right there)

Step#4. Identify the portion of the ozpost code that calculates the final price for any given method. (somewhere around line#1628)

Step#6. Check the value of the ozpost "$skipvalue" variable. (This value hold the number of items skipped from the normal calculations).

Step#7. Add $16.50 to the ozpost calculated totals for each of the skip values (assuming $16.50 for each item of this type),

 

That should do it, but please don't ask me to be any more specific than that.

 

Cheers

Rod

Share this post


Link to post
Share on other sites

Hi @@RodG,

 

Thanks for your input on this. Now that I know where I am looking and what part of the module to change I am pretty sure that I have it right now. Only problem now is that I have another shipping value that I need to calculate the same way for another set of items.

 

This new set of items are the Wall Murals we supply to our customers and need to have a set shipping rate of $25.00.

 

 

How would I go about adding this extra postage rate to the OzPost Module?

 

I presume that it has to have a IF calculation setting as there would have to be IF formula involved as there are 6 different options for shipping calculations.

 

EG. Option 1. Door Mural = $16.50

Option 2. Door Mural + Other item other then the Wall Mural = $16.50 + OzPost Module Calculation.

Option 3. Wall Mural = $25.00

Option 4. Wall Mural + Other item other then the Door Mural = $25.00 + OzPost Module Calculation.

Option 5. Door Mural + Wall Mural = $16.50 + $25.00

Option 6. Door Mural + Wall Mural + Other item other then the Door or Wall Mural = $16.50 + $25.00 + OzPost Module Calc.

 

Am I over complication this issue or have I got it right?

 

If I have it right how the hell do I put these formula's into the OzPost Module so it will work for our store?

 

Currently I have the store setup to calculate these items using the PER ITEM SHIPPING MODULE.

 

Have one of the per item shipping set to $16.50 calculating it using the TAX CLASS as Door Murals and Shipping Zone to Australia.

Copied the same per item shipping and set to $25.00 calculating it using the TAX CLASS as Wall Murals & Shipping Zone to Australia.

 

Unfortunately with this setup the customers still see the OzPost Shipping Module Calculations with these items still.

 

All help appreciated.

Share this post


Link to post
Share on other sites

 

Thanks for your input on this. Now that I know where I am looking and what part of the module to change I am pretty sure that I have it right now. Only problem now is that I have another shipping value that I need to calculate the same way for another set of items.

 

This new set of items are the Wall Murals we supply to our customers and need to have a set shipping rate of $25.00.

 

How would I go about adding this extra postage rate to the OzPost Module?

If I have it right how the hell do I put these formula's into the OzPost Module so it will work for our store?

 

The simple answer is you don't.

 

The ozpost module has been designed with two principles in mind.

1) Protect the merchant (from underquoting)

2) Provide *accurate* quotes.

 

The changes you propose negate these two principles, and neither I, or the ozpost module is going to aid a merchant in shooting themselves in the foot.

 

Currently I have the store setup to calculate these items using the PER ITEM SHIPPING MODULE.

 

Have one of the per item shipping set to $16.50 calculating it using the TAX CLASS as Door Murals and Shipping Zone to Australia.

Copied the same per item shipping and set to $25.00 calculating it using the TAX CLASS as Wall Murals & Shipping Zone to Australia.

 

Unfortunately with this setup the customers still see the OzPost Shipping Module Calculations with these items still.

 

The ozpost module, like all good modules, supports the $this->enabled variable. To disable the ozpost quotes for these items is just a matter of adding a suitable if/then statement somewhere near the start of the ozpost code, but after this variable has been initialised.

 

In simple terms, something like:

 

if ($inCart == $Item) $this->enabled = false ; // will disable the ozpost module if the condition matches

 

You can also add a similar line of code to your per item shipping module so that it only gets enabled if the product(s) match your condition. IOW, by adding the same check to both modules, with one set to 'true' on a match, and the other set to 'false' you can effectively display either the ozpost quotes, or the per item quotes, based on what is in the cart. This would be a far easier 'solution' than trying to hack the ozpost code into doing things it was never designed to do.

 

Cheers

Rod

Share this post


Link to post
Share on other sites

@@FantasyArt - what you want is possible but is too much work for anyone to just "do". I suggest that you post at the commercial forum and get some quotes for these changes.

 

Just because you ask for a quote does not mean you have to go ahead. If you do go ahead (or code it yourself) you can then share the codebase by uploading it as an addon and bask in the glory of all the thank-you's you'll get.


This is a signature that appears on all my posts.  
IF YOU MAKE A POST REQUESTING HELP...please state the exact version
of osCommerce that you are using. THANKS

 
Get the latest Responsive osCommerce CE (community edition) here

Share this post


Link to post
Share on other sites

@@RodG Although I hate to sound stupid but as a relevant newbie in PHP Coding I am not sure what you have stated in the following statement:

 

 

if ($inCart == $Item) $this->enabled = false ; // will disable the ozpost module if the condition matches

 

Is the correct code to use for the OzPost Module to ignore the Per Item Module?

 

Also how does this effect things if products from both places are in the cart? EG: Product A from Per Item + Product B from OzPost Calculated item is in the same cart, does the end result include both of these postage prices calculated together?

 

Sorry for for all the questions still.

 

@@burt Are you able to help with any of this too?

Share this post


Link to post
Share on other sites

Have gotten the following error in the Admin Shipping part, when trying to add any other shipping modules.

 

Warning: include() [function.include]: Failed opening '/home5/fantata1/public_html/store/includes/languages/english/modules/shipping/ozpost1.php' for inclusion (include_path='.:/usr/lib64/php:/usr/lib/php:/usr/share/pear') in /home5/fantata1/public_html/store/admin/modules.php on line 136

 

Could someone please tell me how to fix this?

 

All help appreciated.

 

@@burt As you are online could you please offer some help with this please?

Edited by FantasyArt

Share this post


Link to post
Share on other sites

@@RodG Although I hate to sound stupid but as a relevant newbie in PHP Coding I am not sure what you have stated in the following statement:

 

if ($inCart == $Item) $this->enabled = false ; // will disable the ozpost module if the condition matches

 

Is the correct code to use for the OzPost Module to ignore the Per Item Module?

 

No, its not 'the correct code' as in you can't just cut and paste it. You need to create your own variables to check against. These are generally store or product specific. It isn't something I/we can 'guide' you on. The doing is going to be faster than the explaining.

Also how does this effect things if products from both places are in the cart? EG: Product A from Per Item + Product B from OzPost Calculated item is in the same cart, does the end result include both of these postage prices calculated together?

 

This would depend on your test criteria, but keep in mind that the $this-enabled variable is going to be either true or false, meaning the module(s) will either be enabled or disabled. There is no way to use the quotes from one module to affect the quotes from another (well, not without additional custom coding).

 

Frankly, I don't see why you need to do any of this. The ozpost module has been created so that merchants don't have to use fixed prices, or make adjustments in order to avoid suffering losses. If the module is letting you down somehow then perhaps if you could explain the situation I may be able to suggest a better solution than those you are attempting.

 

Cheers

Rod

 

ps. 'burt' is correct about the file backup/rename.

Edited by RodG

Share this post


Link to post
Share on other sites

@@RodG the reason I require to set these items to post with this specific Postage Cost, EG - Door Mural = $16.50, Wall Mural = $25.00 is that is what I have been told by our supplier that they should be shipped via these prices.

 

I have been told by the supplier that they are shipped by Australia Post Tubes. I don't know the weight of these items yet as the supplier hasn't told me this yet. Others that sell these items also ship using these variables so to be competitive I need to ship at the same rates or less or our customers may go to our competition to purchase these items.

 

I hope that all makes sense as I have had a very long day, been up since 4am and now is 11.40pm.

 

As always, all help is appreciated.

Share this post


Link to post
Share on other sites

@@RodG the reason I require to set these items to post with this specific Postage Cost, EG - Door Mural = $16.50, Wall Mural = $25.00 is that is what I have been told by our supplier that they should be shipped via these prices.

 

I have been told by the supplier that they are shipped by Australia Post Tubes. I don't know the weight of these items yet as the supplier hasn't told me this yet. Others that sell these items also ship using these variables so to be competitive I need to ship at the same rates or less or our customers may go to our competition to purchase these items.

 

I hope that all makes sense as I have had a very long day, been up since 4am and now is 11.40pm.

 

As always, all help is appreciated.

 

Seems to me like you are trying to fix a problem that doesn't exist. If the Murals are posted in the AustPost tubes, then those are the dimensions you'll need to enter for the shipping calculations. Ozpost will provide the correct/actual cost dependent on the destination. If your competitors offer a cheaper rate and you wish to incur the same losses the ozpost module allows you to enter negative handling charges. On the other hand, if your competitors are charging a fixed price shipping for the murals and are not incurring a loss, then they must be overcharging on shipping, in which case the ozpost module will give you the edge by providing the cheapest quotes without incurring a loss.

Hmmm, that's the two main principles I keep telling people about... :)

 

Cheers

Rod

Share this post


Link to post
Share on other sites

@@FantasyArt

You could try my shipping module Separate Shipping Per Product here:

 

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

 

It is on ver 1.5 and it works with v2.3.3 of OsCommerce

Edited by rpetet

Always backup your files! You will be glad you did

My add-ons :

SSPP Seperate Shipping Per Product v2.5| Support
Gift vouchers for SPPC 4.22 v2.1 | Support |
Catalog Infobox v1.0 | Sorry no support for Catalog Infobox |
HTML Mail v2.0 | Support |




Upcoming Add ons:

Addon Manager |
Separate Pricing Per Product Qty |
Coupon Populate |
EZ-PDF Catalog

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×