Return to iWEBTOOL

Go Back   iWEBTOOL Talk > The Web and your Website > Programming > HTML
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
 
Welcome to iWEBTOOL Talk, where you talk about webmaster-related stuff.
 
Discuss topics which interest you.
With over thousands of threads (topics), we're sure you'll find something that'll interest you.
Ask for help whenever you need it.
We have thousands of members who are available to help you if you need it.
It's absolutely FREE!

 1  Register           2  Browse the board           3  Discuss whatever may interest you!
 


Closed Thread
 
Thread Tools Search this Thread Display Modes
Old 09-09-2006, 02:40 AM   #1
johnmr
Newcomer
 
johnmr's Avatar
 
Join Date: Sep 2006
Posts: 1
johnmr will become famous soon enough
Default Centering a DIV

I am building an interface where I have a DIV that gets made visible when you roll over a certain area. The div contains some nav elements, which are jscript rollovers themselves. I've got the code working to hide and show the DIV and to do the rollovers (I've only done the one in the upper left). Here is what it looks like so far:

http://www.artntech.com/sample/index.html

The problem is, I really want the design to be centered, and since I am using absolute positioning for the DIV, this creates a problem. Here is what it looks like when I center the underlying table:

http://www.artntech.com/sample/index2.html

I'm pretty new to all his, and am stumped as to how to get that DIV element to center and align with the underlying table (since it is centered, I can't really predict exactly where it will be in the window).

I've seen articles saying this kind of thing can be one with CSS and have tried several of the samples I've seen with no luck. Anyone know of a good way to do this? Any help greatly appreciated.

Thanks

Johnmr

*
johnmr is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
SEO Checklist
Get yourself better ranking with
our "Do-it-Yourself" SEO Checklist.
Click Here
Old 09-09-2006, 02:27 PM   #2
Zack
Junior Guru
 
Zack's Avatar
 
Join Date: Dec 2005
Location: North Carolina
Posts: 759
Zack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to beholdZack is a splendid one to behold
Send a message via MSN to Zack
Default Re: Centering a DIV

For both of the div's apply the following in the css:

Code:
#divname { width: enter width here; margin-left: auto; margin-right: auto; }
HTMLGuy
__________________
yaxal releases '07
Zack is offline  
 
This is an Ad Revenue Sharing forum Place your advert here
Webmaster Tools Webmaster Tools Click Here
Closed Thread

(Threads which have no activity for more than 30 days are automatically closed.)



Quick Reply
Message:

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Forum Jump


All times are GMT. The time now is 09:19 PM.


Powered by vBulletin v3.6.7 © 2008, Jelsoft Enterprises Ltd. SEO by vBSEO © 2006, Crawlability, Inc.