![]() |
![]() |
![]() |
|||||
![]() |
![]() |
![]() |
![]() |
![]() |
|||
| Welcome
to Tech Support Forum home to more then 136,000 problems solved. Issues
have included: Spyware, Malware, Virus Issues, Windows, Microsoft,
Linux, Networking, Security, Hardware, and Gaming Getting your
problem solved is as easy as: 1. Registering for a free account 2. Asking your question 3. Receiving an answer Registered members: * See fewer ads. * And much more..
|
| Want to know how to post a question? click here | Having problems with spyware and pop-ups? First Steps |
|
|||||||
| Web Design & Programming Discussion of web design, and server-side & client-side scripting |
![]() |
|
|
LinkBack | Thread Tools |
|
|
#1 (permalink) |
|
Registered User
Join Date: Dec 2008
Posts: 165
OS: Linux Mint
|
Tabs in CSS?
Hello all.
I'm having some trouble in CSS. I'm trying to make tabs on top of a webpage, and was told to make each tab a Div. So I did that, and they end up getting stacked up on eachother. Heres the code for my tabs: Code:
#tabs
{
backgound-color: white;
height: 20px;
width: 950px;
margin-left: auto;
margin-right: auto;
}
#tab1
{
text-aline: left;
backgound-color: white;
height: 0px;
width: 95px;
padding-left: 20px;
}
#tab2
{
text-aline: left;
backgound-color: white;
height: 0px;
width: 95px;
padding-left: 115px;
}
#tab3
{
text-aline: left;
backgound-color: white;
height: 0px;
width: 95px;
padding-left: 230px;
}
#tab4
{
text-aline: left;
backgound-color: white;
height: 0px;
width: 95px;
padding-left: 345px;
}
#tab5
{
text-aline: left;
backgound-color: white;
height: 0px;
width: 95px;
padding-left: 560px;
}
Any help plz? Thanks.
__________________
bLUE445 |
|
|
|
| Important Information |
|
Join the #1 Tech Support Forum Today - It's Totally Free!
TechSupportForum.com is a leading support website for your computer needs. We offer free, friendly and personalized computer support. Why pay to have your computer fixed when you can do it for free. Join TechSupportforum.com Today - Click Here |
|
|
#2 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
If the navbar is working as planned, aside from this little problem, just add {display: inline} under div in the CSS.
Please keep in mind that spelling does count for all kinds of programming. If not: we can create the navbar from a list of items. We just have to do some basic CSS tweaks to make it display the way we want. This site should give you the basic idea: http://www.456bereastreet.com/archiv...avigation_bar/
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
|
|
#5 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
Just add {background-image: url(relative_url_of_image)} to div.
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
|
|
#7 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
Sorry, that should be background, not background-image. I was thinking of something else at the time and it screwed me up.
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
|
|
#9 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
Are you using a relative URL or a complete URL? The relative URL begins in the FTP upload folder, and continues from that point. If you put the site address, it stuffs up.
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
|
|
#10 (permalink) |
|
Registered User
Join Date: Dec 2008
Posts: 165
OS: Linux Mint
|
Re: Tabs in CSS?
Well, I'm using a local image. Lets say I had two folders.
-Website -CSS -Images I would type in my css: url(images/header.png) Correct? The website is one folder, and has two separate folders, the css and another the images.
__________________
bLUE445 |
|
|
|
|
|
#11 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
All right, I've got myself all tied up in knots. Let me try to debug this for you.
Code:
background: #FFFFFF url(../images/header.png) no-repeat center; I'm sorry for any confusion and inconvenience that may have resulted from my screwing up.
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
|
|
#12 (permalink) |
|
Registered User
Join Date: Dec 2008
Posts: 165
OS: Linux Mint
|
Re: Tabs in CSS?
It still being silly and not showing up
Heres the small HTML gallary Code:
<!--TABS SECTION--> <div id="tabs"> <ul id="nav"> <li id="nav-home"><a href="#">Home</a></li> <li id="nav-about"><a href="#">Services</a></li> <li id="nav-archive"><a href="#">Gallery</a></li> <li id="nav-lab"><a href="#">About Us</a></li> <li id="nav-reviews"><a href="#">Contact Us</a></li> </ul> </div> Code:
#tabs
{
width: 950px;
height: 26px;
margin-left: auto;
margin-right: auto;
background: #FFFFFF url(../images/header.png) no-repeat center;
}
__________________
bLUE445 |
|
|
|
|
|
#13 (permalink) |
|
Moderator: Design
Join Date: Oct 2006
Location: Richmond, B.C.; Canada
Posts: 1,463
OS: Windows XP [Version 5.1.2600] SP3 | Ubuntu Jaunty Jackalope | Windows 7 Ultimate (MSDNAA I <3 you)
|
Re: Tabs in CSS?
How about a little test. Replace the #FFFFFF with #0600FF and see if there is a difference. If there is, check the URL. If there isn't, check your speling.
__________________
![]() Validate your Markup Validate your CSS Notepad++ Please use [html], [php], and [code] when posting code or markup. I do not help by Private Message or e-mail. If for some reason I have over-looked a reply to a thread that I have previously replied to, then send me a message. |
|
|
|
![]() |
| Thread Tools | |
|
|