Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Graduated Shipping Cost by Price Purchase


Babysweet

Recommended Posts

I am constrained by my dropshipper who basis his shipping costs on the price of purchase. However unfair I think this is, I am limited by their policy. I could write the program itself for this module, however, I am weary of creating errors in the overall program's function, and tracking down all the variables I would need to make such a module function.

If there is such a shipping cost module already in existance I would appriciate obtaining it.

If there does not exist such a module, then if I can be given instruction on which parts of the overall program I need to make changes and which variable I must use in creating a module for myself

Thank you for any assistance.

Sincerely.

Joe

Sincerely,

Joseph Seabert

Link to comment
Share on other sites

Now I tried this however it does not work, maybe someone can tell me why,

 

I placed this code into the checkout_confirmation.php and deleted the shipping module section. I am no programer wiz, so if this looks bad its probably because it is. lmao, well your help will be apprieciated

 

 

$first_grad = 25;
$first_grad_cost = 5.95;
$second_grad = 40;
$second_grad_cost = 6.95;
$third_grad = 55;
$third_grad_cost = 7.95;
$fourth_grad = 70;
$fourth_grad_cost = 8.95;
$fifth_grad = 85;
$fifth_grad_cost = 9.95;
$sixth_grad = 200;
$sixth_grad_cost = 10.95;
$greater_grad_cost = 12.95;

if ($total_cost <= $first_grad)
{
        $shipping_cost = $first_grad_cost;
}
elseif ($total_cost > $first_grad)
{
      If ($total_cost <= $second_grad)
      {
             $shipping_cost = $second_grad_cost;
       }
      elseif ($total_cost > $second_grad)
      {
             if ($total_cost <= $third_grad)
             {
                $shipping_cost = $third_grad_cost;
             }
             elseif ( $total_cost > $third_grad)
             {
                    if ($total_cost <= $forth_grad)
                      {
                               $shipping_cost = $forth_grad_cost;
                      }
                      elseif ($total_cost > $forth_grad)
                      {
                                  if ($total_cost <= $fifth_grad)
                                     {
                                       $shipping_cost = $fifth_grad_cost;
                                     }
                                    elseif ($total_cost > $fifth_grad)
                                     {
                                             if ($total_cost <= $sixth_grad)
                                               {
                                                  $shipping_cost = $sixth_grad_cost;
                                                }
                                               elseif ( $total_cost > $sixth_grad)
                                              {
                                                 $shipping_cost = $greater_grad_cost;
                                               }
                                      }
                      }
            }
     }  
}            
     

Sincerely,

Joseph Seabert

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...