troubleshooting Question

CSS - and DIV Padding

Avatar of Pete Long
Pete LongFlag for United Kingdom of Great Britain and Northern Ireland asked on
Web Languages and StandardsWeb DevelopmentCSS
11 Comments1 Solution520 ViewsLast Modified:
Hi All

I've done some Google searching and cant really find an answer that I'm happy with.

I have a site that is controlled by a couple of CSS files. I want to add a search box on the site (that's fine I just paste in the code for the search).

But I want to put it in a <div> and set the padding etc. on it so i can squeeze/push it so it lines up neatly with other elements on the site.

I know I can declare a DIV ID in the CSS, then reference that on each on my pages, but I don't know the syntax, nor can I work out what I need to do (I'm not a web developer, I do my best to struggle along.)

Here you can see the search box (the one below all the header/buttons, I need to pop it in a <DIV>, apply padding to the left/Right/Top

My CSS is here

What do I need to put in the CSS, and what do I need to put on the page?
If you could explain what the code is doing so I can learn something, that would also be a bonus.

Thanks in advance.

Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 11 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 11 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros