-
Floating Divs with padding
Brilliant! Thank you very much mealybar - I feel a bit stupid for not realising how simple it was! Cheers =]
-
Floating Divs with padding
I have a div in my page which I want to be split into 2 columns of equal width. Currently, I have a container div for the body of the site and then two divs within the container. One is floated left and the other floated right within the container (both are 50% width). It looks how I want it to, other than there is very little gap between the two divs, making it hard to read the text within them. I have tried adding both padding and margins to either (and both) of the left and right divs but nothing seems to space them apart. How can I increase the gap between them? Or, is there a better way of splitting a div into 2 columns? <div id="body"> <div id="body_left"> <p>Body text left......</div><!--end body_left--> <div id="body_right"> Body text right... </div><!--end body_right--> </div><!-- end body--> #body { margin-top: 1em; padding-left: 7px; padding-right: 7px; padding-bottom: 7px; padding-top: 5px; border: 1px solid #666; -moz-border-radius: 4px; -webkit-border-radius: 4px; } #body_left { float: left; width: 50%; } #body_right { float: right; width: 50%; } EDIT-- Thought a diagram may help explain what I mean. The light blue is the container div and the pink and dark blue ones are the 50% width ones. Basically, I want the gap (where the arrow is pointing) to be bigger.
-
Customise Search Boxes
Yer sure - the site was http://www.mattdempsey.com/ All I did was look in the CSS http://www.mattdempsey.com/css/style.css and found the bits that related to the contact form (starts at line 445). I'm afraid I can't offer much help at the minute concerning what it does as I'm still learning myself - all I can make out is that some attributes affect the <li> tags that surround the input fields and some attributes directly affect the input fields. From my tests I don't think that it is necessary to put <li> tags around the input fields. Hope that helps Chris
-
Customise Search Boxes
Thanks for the heads-up on Firebug. Just by chance I came across another site with the same features so I used Firebug on that site to work it out - the iPlayer site was a bit complex. Cheers again Chris
-
Customise Search Boxes
I have seen a number of sites where the search box has rounded corners, the text is in a different font to usual and the actual search button is a graphic. The only one which comes to mind at the minute is BBC iPlayer (http://www.bbc.co.uk/iplayer) but there are quite a few around. How do I do this? Does it rely on CSS or Javascript (or something else altogether? Thanks, Chris