Developer forum

Forum » Templates » Basket - Delivery address not being recorded

Basket - Delivery address not being recorded

Gaëtan Di Caro
Reply

Hi,

I have a solution based on the wrap, and in the basket the user has the possibility to choose an alternative delivery address from his address list (I change the values of the delivery address fields via javascript on select). My delivery address fields are defined this way:

<input type="text" style="width: 100%" class="form-control" name="EcomOrderDeliveryCompany" id="EcomOrderDeliveryCompany" placeholder="@Translate("Company", "Company")" disabled/>

However, even though the fields are filled, the order doesn't remember them. After placing the order, the delivery address doesn't appear in the order (not even in the backend). I can't seem to find out why I have this problem as I have other solutions which do the same without problem. There most be something not configured well but I can't find what. Any idea where I can look ?

Thanks

 


Replies

 
Morten Bengtson Dynamicweb Employee
Morten Bengtson
Reply

Hi GaĆ«tan,

The input field in your example is marked with the disabled attribute. This usually means that the value will not be posted back to the server.
Try using the readonly attribute instead.

Best regards,
Morten

 
Gaëtan Di Caro
Reply

Ah yes of course, I forgot about that behaviour. The data comes through now, thanks.

I just have one problem with the country :

<input type="text" style="width: 100%" class="form-control" name="EcomOrderDeliveryCountry" id="EcomOrderDeliveryCountry" placeholder="@Translate("Country", "Country")" readonly="readonly" />

Can the delivery country just be simple text or does it have to be set completely (including the country code and all) ?

Thanks !

 

 

You must be logged in to post in the forum