lucy Posted August 21, 2009 Share Posted August 21, 2009 I want to create a search bar, which is rectangular with right angled edges, but i can only get one with rounded(ish) corners. See images below: I want the search bar to look like this: but i can only get it to look like this: Can anyone give me a solution or point me in the right direction please. Thanks, Lucy Link to comment https://forums.phpfreaks.com/topic/171309-how-to-change-shape-of-text-field/ Share on other sites More sharing options...
lostprophetpunk Posted August 21, 2009 Share Posted August 21, 2009 Put an id to the search field, such below... <input type='text' id='search' name='search' /> <input type='submit' value='search' name='search' /> Change the 'name=' to the names you already have. Then apply some CSS to the input, put this in the header... <style type='text/css' ref='stylesheet'> #search { padding-5px; /* adjust to make it fit with the image */ margin-right: -5px; } </style> You can put the CSS in with your file, if you have it already. Hope that helped. Link to comment https://forums.phpfreaks.com/topic/171309-how-to-change-shape-of-text-field/#findComment-903443 Share on other sites More sharing options...
lucy Posted August 21, 2009 Author Share Posted August 21, 2009 Yes that has made the image stick by the search box, but it has not made the search box with sharp 90 degree corners as in the image, it has kept the box with rounded corners. How can i make the corners sharp? Thanks Link to comment https://forums.phpfreaks.com/topic/171309-how-to-change-shape-of-text-field/#findComment-903485 Share on other sites More sharing options...
lostprophetpunk Posted August 21, 2009 Share Posted August 21, 2009 Yes that has made the image stick by the search box, but it has not made the search box with sharp 90 degree corners as in the image, it has kept the box with rounded corners. How can i make the corners sharp? Thanks Just add this to the CSS of the '#search'... border: 0px; Hope this helps. Link to comment https://forums.phpfreaks.com/topic/171309-how-to-change-shape-of-text-field/#findComment-903497 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.