View Single Post
  #30  
Old 01-17-2005, 08:29 PM
 
joestern joestern is offline
 

Senior Member
  
Join Date: Apr 2004
Posts: 185
 

Default

Update: I've figured out where the problem is, but can't seem to get it fixed.

There are two problems; one I have figured out. The firstname/lastname needed to be "b_firstname" and "b_lastname"...easy.

It also appears that it is the "state" code that is causing a problem. If I remove all of the state code from copybilling.js, it works fine, but of course does not copy the state over. I'm wondering whether 3.x handles the state selection differently than 4.x. Here is my states.tpl file:

Code:
{* $Id: states.tpl,v 1.1.4.3 2004/04/09 07:07:28 svowl Exp $ *} {if $states ne ""} <select name="{$name}" {$style}> {* <option value="XX">Please Select Below</option> *} {section name=state_idx loop=$states} <option value="{$states[state_idx].state_code}"{if $default eq $states[state_idx].state_code and $default_country eq $states[state_idx].country_code} selected{/if}>{$states[state_idx].state}</option> {/section} </select> {else} <input type=text size=32 name="{$name}" value="{$default}"> {/if}

Here's the relevant part of register_billing_address.tpl:

Code:
<tr valign=middle> <td align=right>{$lng.lbl_state}</td> <td>{if $states ne ""}<font class=Star>*</font>{/if}</td> <td nowrap> {include file="main/states.tpl" states=$states name="b_state" default=$userinfo.b_state default_country=$userinfo.b_country} </td> </tr>

Any thoughts would be greatly appreciated.
__________________
X-Cart version 4.7.12
Reply With Quote