View Single Post
  #2  
Old 01-08-2009, 11:37 PM
  Victor D's Avatar 
Victor D Victor D is offline
 

X-Adept
  
Join Date: Aug 2008
Posts: 643
 

Default Re: Retaining selected Item in dropdown menu

HTML Code:
<option value=$year selected="selected">"$year"</option>
More correct
HTML Code:
<option value="{$year}" selected="selected">{$year}</option>


Also it may be caused by duplicating options with the same value
F.e. if 2009 is selected you will get
HTML Code:
<option value="2009" selected="selected">2009</option> <option value="2009">2009</option>
Try to use foreach or section cycle to output options
__________________
Regards,
Victor Dubiniuk

X-Cart Skins Store
- twenty two different skins for 4.1.x and 4.2.x;
- 4.3.x compatible versions are available;
- refresh you store now!

Smart menu X-Cart add-on for 4.1.8 - 4.3.x
Featured Products Slide Show X-Cart add-on for 4.1.8 - 4.3.x
Reply With Quote