johnseito Posted July 15, 2008 Share Posted July 15, 2008 <input name="firstname" type="text" value ="firstname"/> Does anyone know how to make the input value firstname in this example to a graycolor or any other color? thanks, Link to comment https://forums.phpfreaks.com/topic/114763-make-field-value-color/ Share on other sites More sharing options...
sader Posted July 15, 2008 Share Posted July 15, 2008 <input name="firstname" type="text" value ="firstname" style="color:gray; background-color:red"/> http://www.w3schools.com/Css/default.asp Link to comment https://forums.phpfreaks.com/topic/114763-make-field-value-color/#findComment-590096 Share on other sites More sharing options...
PseudoEvolution Posted July 15, 2008 Share Posted July 15, 2008 ^ Beat me to it! You can also apply background color, borders, size etc... Link to comment https://forums.phpfreaks.com/topic/114763-make-field-value-color/#findComment-590097 Share on other sites More sharing options...
johnseito Posted July 15, 2008 Author Share Posted July 15, 2008 Kool thanks, how about option values? such as this: <option value="" <?php if ($_POST['gender'] == '') echo ' selected="selected"'; ?>>- Select One -</option> and ones with loops etc Link to comment https://forums.phpfreaks.com/topic/114763-make-field-value-color/#findComment-590105 Share on other sites More sharing options...
sader Posted July 15, 2008 Share Posted July 15, 2008 U should learn what is Cascading Style Sheet (css) and how to work with it Link to comment https://forums.phpfreaks.com/topic/114763-make-field-value-color/#findComment-590111 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.