I have alot of forms that will require select imputs, but none of the first options are ever populated. Looking at the code, Contour is creating an empty "option" tag in the "select" input so there is a blank field for the first item in the dropdown. Is there a way to prevent Contour from creating an empty option tag?
I had the same problem - But if you update to Contour 3.0 you can modify the form markup easily.
I decided to add the text "...please select..." to the empty option tag. But I guess you also can just remove this empty option tag in the razor file.
You can find the razor file in the folder \umbraco\plugins\umbracoContour\Views. There you can edit the file "FieldType.DropDownList.cshtml" and modify the markup.
Selects create an empty "option" tag
I have alot of forms that will require select imputs, but none of the first options are ever populated. Looking at the code, Contour is creating an empty "option" tag in the "select" input so there is a blank field for the first item in the dropdown. Is there a way to prevent Contour from creating an empty option tag?
Hi Steve,
I had the same problem - But if you update to Contour 3.0 you can modify the form markup easily.
I decided to add the text "...please select..." to the empty option tag. But I guess you also can just remove this empty option tag in the razor file.
You can find the razor file in the folder \umbraco\plugins\umbracoContour\Views. There you can edit the file "FieldType.DropDownList.cshtml" and modify the markup.
The procedure is also explained in this video http://umbraco.com/follow-us/blog-archive/2012/11/8/contour-30-features-full-control-over-form-markup.aspx
is working on a reply...