Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

html_option selected anomaly

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Bugs
View previous topic :: View next topic  
Author Message
jamgold
Smarty n00b


Joined: 07 Oct 2004
Posts: 3

PostPosted: Sat Nov 20, 2004 7:21 am    Post subject: html_option selected anomaly Reply with quote

Hi

today I finally figured out why the html_option call did sometimes not display the correct option, according to the selected parameter.

The html_option plugin uses the in_array function to determine if an option is supposed to be selected or not.

I happen to use option values of 1.3.2.1 or 2.1.3 or 2.1 to signify tree / children dependencies.

The problem is that all 2-digit option values are being interpreted as numbers rather than strings and therefore don't achieve the desired match.

Is this really what's happening, or am I on crack? How would I best fix this, short of writing my own html_option plugin or changing the separation character of my tree structure (.)?

Thanks

Jan
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Bugs All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP