Link to home
Start Free TrialLog in
Avatar of Paul Tomasi
Paul TomasiFlag for United Kingdom of Great Britain and Northern Ireland

asked on

DIV question

If I have a header at the top of a page created using DIV, and I want to place a logo image to the left and text (phone number) to the right, do I need to define and use two seperate embedded DIVs?

And how would I position them? And can I make them relative to the 'header' region instead of the page itself?
Avatar of Paul Tomasi
Paul Tomasi
Flag of United Kingdom of Great Britain and Northern Ireland image

ASKER

Or, should I use a table inside the header DIV to create 2 side-by-side regions?
I was able to do it using a 2-col single-row table...
ASKER CERTIFIED SOLUTION
Avatar of SSupreme
SSupreme
Flag of Belarus image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SSupreme

Thank you for your reply.

Will implement your suggestion and confirm...
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
As I mentioned earlier.
Okay, I've tried so hard to put a site together using DIVs I've abandoned them in favour of tables for now.

I will award point regardless and accordingly.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
amitlamba, what are you doing? spamming?
amitlamba

I didn't know you could that. I love the idea of #header img... and #header p... to define styles relative to DIVs whose ID is 'header'.

Your simplified solution has made a few things clearer to me (okay, call me a 'newbie'...).

Looking at your code, I think the key element is the 'float:left' and 'float:right'...

I can't understand why I did not pick this up when looking at SSupreme's code (which is almost identical to your own). Maybe it's because at the time I didn't know what to look for at the time.

Thank you for your effort and time. Pity I cannot give you points too.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
it is good that you call the header image in the background and all the logo image and phone number you can just type in the header div.
also you can give the link in the logo

i think it will help you..
thanks.