zeelot / kohana-yform

Form Generation =(
15 stars 2 forks source link

Extra space in output of <option> #26

Open alanhogan opened 14 years ago

alanhogan commented 14 years ago

In the case where an option is not selected, it will have an extra space.

    <option value="" selected="selected"></option> 
    <option value="AK" >Alaska</option> 

The fix:

http://pastebin.com/UZEpaxjR

jeremeamia commented 14 years ago

There are actually extra spaces all over the HTML outputted by yform. One thing to remember is that the output of HTML::attributes() begins with a space.

zeelot commented 14 years ago

is it invalid html to have a space before the closing '>' ?

jeremeamia commented 14 years ago

No, it's just dumb.

alanhogan commented 14 years ago

Lorenzo, did you apply the change?