Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Showing shipping period within the cart.

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #11  
Old 01-04-2007, 09:11 PM
 
inebriate inebriate is offline
 

eXpert
  
Join Date: May 2006
Posts: 301
 

Default Re: Showing shipping period within the cart.

i just implemented this a few days ago since it doesnt display when using real time shipping...this mod will pull the shipping time that you define in the admin's shipping method section

in shipping/shipping.php
Code:
foreach($intershipper_rates as $intershipper_rate) { $ship_time = ""; if (!empty($intershipper_rate["shipping_time"])) $ship_time = $intershipper_rate["shipping_time"]." ".($intershipper_rate["shipping_time"]>"1" ? "days" : "day"); $result = func_query_first("SELECT *, '$intershipper_rate[rate]' AS rate, '$intershipper_rate[warning]' AS warning, '$ship_time' AS shipping_time FROM $sql_tbl[shipping] WHERE subcode='$intershipper_rate[methodid]' AND active='Y' $weight_condition ORDER BY orderby"); if ($result) $shipping[] = $result; }
and replace it with
Code:
foreach($intershipper_rates as $intershipper_rate) { $ship_time = ""; if (!empty($intershipper_rate["shipping_time"])) { $ship_time = $intershipper_rate["shipping_time"]." ".($intershipper_rate["shipping_time"]>"1" ? "days" : "day"); $result = func_query_first("SELECT *, '$intershipper_rate[rate]' AS rate, '$intershipper_rate[warning]' AS warning, '$ship_time' AS shipping_time FROM $sql_tbl[shipping] WHERE subcode='$intershipper_rate[methodid]' AND active='Y' $weight_condition ORDER BY orderby"); } else { $result = func_query_first("SELECT *, '$intershipper_rate[rate]' AS rate, '$intershipper_rate[warning]' AS warning, shipping_time FROM $sql_tbl[shipping] WHERE subcode='$intershipper_rate[methodid]' AND active='Y' $weight_condition ORDER BY orderby"); } if ($result) $shipping[] = $result; }


then in skin1/customer/main/cart_totals.tpl, find
Code:
<SELECT name="shippingid" onchange="document.cartform.submit()"> {section name=ship_num loop=$shipping} <OPTION value="{$shipping[ship_num].shippingid}" {if $shipping[ship_num].shippingid eq $cart.shippingid}selected{/if}>{$shipping[ship_num].shipping|trademark:$insert_trademark:"alt"}{if $config.Appearance.display_shipping_cost eq "Y" and ($login ne "" or $config.General.apply_default_country eq "Y" or $cart.shipping_cost gt 0)} ({include file="currency.tpl" value=$shipping[ship_num].rate}){/if}</OPTION> {/section} </SELECT>
and replace with
Code:
<SELECT name="shippingid" onchange="document.cartform.submit()"> {section name=ship_num loop=$shipping} <OPTION value="{$shipping[ship_num].shippingid}" {if $shipping[ship_num].shippingid eq $cart.shippingid}selected{/if}>{$shipping[ship_num].shipping|trademark:$insert_trademark:"alt"}{if $shipping[ship_num].shipping_time ne ""} : {$shipping[ship_num].shipping_time}{/if} {if $config.Appearance.display_shipping_cost eq "Y" and ($login ne "" or $config.General.apply_default_country eq "Y" or $cart.shipping_cost gt 0)} ({include file="currency.tpl" value=$shipping[ship_num].rate}){/if}</OPTION> {/section} </SELECT>
__________________
x-cart pro 4.0.18
linux
www.fabric8d.com (currently undergoing construction)
Reply With Quote
  #12  
Old 01-08-2007, 06:03 AM
 
david_ygao david_ygao is offline
 

Advanced Member
  
Join Date: Feb 2005
Location: canada
Posts: 40
 

Default Re: Showing shipping period within the cart.

I do not know how to fix this problem with UPS shipping module since I am not familair with the software language.

UPS technical support told me UPS has changed sth after New Year, and our shopping cart software needs updating.

Tahnks,

david
xcart 4.18 gold
__________________
/David Gao/
X-cart business 5.3.6
Reply With Quote
  #13  
Old 01-18-2007, 09:59 AM
  neaisha's Avatar 
neaisha neaisha is offline
 

eXpert
  
Join Date: May 2006
Posts: 276
 

Default Re: Showing shipping period within the cart.

inebriate,

before i screw something up, i was wondering if this fix works for 4.1.x as well?
__________________
X-Cart Gold 4.4.3
--------------------------------------
Reply With Quote
  #14  
Old 01-18-2007, 10:08 AM
  neaisha's Avatar 
neaisha neaisha is offline
 

eXpert
  
Join Date: May 2006
Posts: 276
 

Default Re: Showing shipping period within the cart.

and the survey says...yes

thanks
__________________
X-Cart Gold 4.4.3
--------------------------------------
Reply With Quote
  #15  
Old 08-26-2007, 03:52 PM
 
millsryno millsryno is offline
 

Advanced Member
  
Join Date: Nov 2006
Posts: 36
 

Default Re: Showing shipping period within the cart.

This works excellent, just what I was looking for. Thanks!
__________________
X-Cart Version 4.0.19
DSEFU PRO
www.HandPouredWorms.com
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 06:06 AM.

   

 
X-Cart forums © 2001-2020