By: Anthony
Date: 2012-04-10
Time: 21:46
|
HTML Select and Empty ValuesHow does one get TBS to not make a selection and leave select blank when the field is empty? The first way I did it selects one of the options although the field from the database is empty. The second way I tried does not work either. The third way works but puts an empty selection in the dropdown, which I don't want.
First Way:
Second Way:
Third Way:
|
|||
By: Skrol29
Date: 2012-04-10
Time: 23:48
|
Re: HTML Select and Empty ValuesHi Anthony,
If the value is not found, then the plug-in does not select any option in the template. If you can the the first item selected, it is probably because of the navigator. But if you check the HTML source of the result, it should be no selected item. |
|||
By: Anthony
Date: 2012-04-11
Time: 04:57
|
Re: HTML Select and Empty ValuesYou are correct that in the html source there is no selected item, but only the third way I spoke of above allows me to have no selection showing when the field from the DB is empty. It appears that is the way to provide for a blank selection.
|
|||
By: Skrol29
Date: 2012-04-11
Time: 15:22
|
Re: HTML Select and Empty ValuesYou can also use parameter "addmissing" like this : [songblock.genre;ope=html;select;addmissing]
Then the empty item will be added (and selected by the way) only if the value is empty. http://www.tinybutstrong.com/plugins.php?help#plugin_html |
|||
By: Anthony
Date: 2012-04-11
Time: 16:26
|
Re: HTML Select and Empty ValuesThanks!
|