Graphic Design Forum and Web Design Forum  

Go Back   Graphic Design Forum and Web Design Forum »Web Design Forum »CSS Forum

Notices

CSS Forum Cascading Style Sheets (CSS) and XHTML Forum


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-03-2008, 08:21 PM
Junior Member
 
Join Date: Jan 2008
Location: Location Location
Posts: 43
Default small problem

for some reason when i put text in a <H> tag on my site, it pushes the text down?? i have no idea why its doing it. The code for my <h> tags is:

H1, H2, H3, H4 {
font-family:Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
}
H1 {font-size: 14px; color:#FF6600;}
H2 {font-size: 12px; color:#FF6600;}
H3 {font-size: 12px;}
H4 {font-size: 12px;}

If i put say <H1> </H1> around some text it pushes it down about 1/2 inch.

anyone got any ideas why its doing it??
__________________
www.bretoncottage1654.co.uk
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote

  #2 (permalink)  
Old 03-03-2008, 09:34 PM
tommylogic's Avatar
f*ck yeah it validates!!!
 
Join Date: Apr 2007
Location: Virtually Everywhere
Gender: Male
Posts: 5,853
Default

it's probably your browser.. do you have a link?
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #3 (permalink)  
Old 04-03-2008, 07:35 AM
Toon's Avatar
Netvibes is an Addiction™
 
Join Date: Jan 2007
Location: Sheffield, UK
Gender: Male
Posts: 18,757
Default

Quote:
Originally Posted by alex_gomy View Post
for some reason when i put text in a <H> tag on my site, it pushes the text down?? i have no idea why its doing it. The code for my <h> tags is:

H1, H2, H3, H4 {
font-family:Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
}
H1 {font-size: 14px; color:#FF6600;}
H2 {font-size: 12px; color:#FF6600;}
H3 {font-size: 12px;}
H4 {font-size: 12px;}

If i put say <H1> </H1> around some text it pushes it down about 1/2 inch.

anyone got any ideas why its doing it??
Why use uppercase? I would start there
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #4 (permalink)  
Old 04-03-2008, 09:14 AM
Batfink
 
Join Date: Feb 2007
Location: Midlands
Gender: Male
Posts: 58
Default

<h> tags have a top margin, you just need to set this to zero i.e.

h1{
margin:0 0 15px 0;
}
__________________
benchmarc
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #5 (permalink)  
Old 04-03-2008, 01:01 PM
tommylogic's Avatar
f*ck yeah it validates!!!
 
Join Date: Apr 2007
Location: Virtually Everywhere
Gender: Male
Posts: 5,853
Default

I forget that people forget to clear all their margins at the top of their CSS... I recommend starting your CSS file like so:

Code:
body, h1, h2, h3, h4, p, ul, li {
    margin: 0px;
    padding: 0px;
}
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #6 (permalink)  
Old 04-03-2008, 01:14 PM
Batfink
 
Join Date: Feb 2007
Location: Midlands
Gender: Male
Posts: 58
Default

Good call, all of my style sheets currently start with:

body, h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, img, strong, dl, dt, dd, ol, ul, li,
fieldset, form, label, legend, table, tr, th, td {
margin:0;
padding:0;
border:none;
}
__________________
benchmarc
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #7 (permalink)  
Old 04-03-2008, 06:22 PM
Junior Member
 
Join Date: Jan 2008
Location: Location Location
Posts: 43
Default

Sweet that worked... cheers for being helpful all.
__________________
www.bretoncottage1654.co.uk
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #8 (permalink)  
Old 05-03-2008, 11:51 AM
misterm's Avatar
Junior Member
 
Join Date: Mar 2008
Location: The Netherlands
Posts: 49
Default

Quote:
Originally Posted by tommylogic View Post
I forget that people forget to clear all their margins at the top of their CSS... I recommend starting your CSS file like so:

Code:
body, h1, h2, h3, h4, p, ul, li {
    margin: 0px;
    padding: 0px;
}
Or even quicker
Code:
*{
margin:0;
padding:0;
}
This will reset all the standards padding/margin values off all browsers and makes them render pretty much alike. Just in case, stay aware of the box-model.
__________________
- The problem is how to remain an artist once you grow up.
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #9 (permalink)  
Old 05-03-2008, 12:34 PM
Batfink
 
Join Date: Feb 2007
Location: Midlands
Gender: Male
Posts: 58
Default

The universal selector will reset styles on all tags, so bear in mind that you will have to re-style everything...
__________________
benchmarc
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
  #10 (permalink)  
Old 05-03-2008, 12:36 PM
tommylogic's Avatar
f*ck yeah it validates!!!
 
Join Date: Apr 2007
Location: Virtually Everywhere
Gender: Male
Posts: 5,853
Default

yeah exactly... some what overkill
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati Share This Article & VoteReddit! Wong this Post!Stumble this Post!RSS Share on FacebookForum Netvibes Page
Reply With Quote
Reply


Thread Tools
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
I need to get my small biz online Jenny Goldberg Graphic Design and Web Design Help 3 22-04-2008 09:35 AM
Need logo for my small company iman Logo Design & Brand Identity Forum 14 08-11-2007 07:09 PM
My small website :] Communist-Cola Advertising Forum 21 18-06-2007 09:01 PM
Small dig at 2.0 Toon General Web Design Forum 1 07-06-2007 10:01 AM
Small Oppertunity Toon General Web Design Forum 4 01-03-2007 05:37 PM


All times are GMT. The time now is 10:23 PM.



Estetica Design Forum's Privacy Policy
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0