Styling the <h1> tag.

This is a discussion on "Styling the <h1> tag." within the Web Page Design section. This forum, and the thread "Styling the <h1> tag. are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Jul 28th, 2006, 13:23
minute44's Avatar
Moderator
Join Date: Apr 2006
Location: Nottingham UK
Age: 25
Posts: 1,350
Blog Entries: 1
Thanks: 0
Thanked 1 Time in 1 Post
Styling the <h1> tag.

I have a question.

On this site:
http://chrisgarrettmedia.com/

This guy's <h1> is styled to be his logo but it also has text that is not visible when his CSS is applied. So when you remove all style information it displays the text and nothing seems broken.

How do you achieve this? It's a really cool effect and is super accessible.

Anyone?

Cheers in advance.

Dan.
Last Blog Entry: Annoying people.... (Jan 16th, 2008)
Reply With Quote

  #2 (permalink)  
Old Jul 28th, 2006, 14:33
craig's Avatar
Reputable Member
Join Date: Sep 2005
Location: Preston, UK
Age: 21
Posts: 381
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Styling the <h1> tag.

It seems he's defining the words to be displayed off the page. He has it set at -9000px to the left.
I woudn't call it accessible, you cant resize the font of the logo

http://chrisgarrettmedia.com/index.p...ntation/screen

Craig
Reply With Quote
  #3 (permalink)  
Old Jul 28th, 2006, 14:43
minute44's Avatar
Moderator
Join Date: Apr 2006
Location: Nottingham UK
Age: 25
Posts: 1,350
Blog Entries: 1
Thanks: 0
Thanked 1 Time in 1 Post
Re: Styling the <h1> tag.

Quote:
Originally Posted by craig View Post
It seems he's defining the words to be displayed off the page. He has it set at -9000px to the left.
I woudn't call it accessible, you cant resize the font of the logo

http://chrisgarrettmedia.com/index.p...ntation/screen

Craig
Hmm, surprised that doesn't cause a horizontal scrollbar... you'd think it would wouldn't you?
Last Blog Entry: Annoying people.... (Jan 16th, 2008)
Reply With Quote
  #4 (permalink)  
Old Jul 28th, 2006, 15:20
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,948
Blog Entries: 1
Thanks: 0
Thanked 29 Times in 29 Posts
Re: Styling the <h1> tag.

Probably something like this.

h1#foo {
width:;
height:;
background:url("foo.jpg") top left no-repeat;
}

h1#foo a {
visibility:hidden !important;
}
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #5 (permalink)  
Old Jul 28th, 2006, 15:21
minute44's Avatar
Moderator
Join Date: Apr 2006
Location: Nottingham UK
Age: 25
Posts: 1,350
Blog Entries: 1
Thanks: 0
Thanked 1 Time in 1 Post
Re: Styling the <h1> tag.

Ahh yes, you're probably right there.

Question: Why do you call everything "foo" when you post on here?
Last Blog Entry: Annoying people.... (Jan 16th, 2008)
Reply With Quote
  #6 (permalink)  
Old Jul 28th, 2006, 15:24
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,948
Blog Entries: 1
Thanks: 0
Thanked 29 Times in 29 Posts
Re: Styling the <h1> tag.

Foo is a generic term used to specify items in an example.

Here is a definition of the term:

"A metasyntactic variable is a placeholder name, or a kind of alias term, commonly used to denote the subject matter under discussion, or a random member of a class of things under discussion. The term originates from computer programming and other technical contexts, and is commonly used in examples by hackers and programmers.
The use of a metasyntactic variable is helpful in freeing a programmer from creating a logically named variable, although the invented term may also become sufficiently popular and enter the language as a neologism. The word foo is the canonical example"
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #7 (permalink)  
Old Jul 28th, 2006, 15:26
minute44's Avatar
Moderator
Join Date: Apr 2006
Location: Nottingham UK
Age: 25
Posts: 1,350
Blog Entries: 1
Thanks: 0
Thanked 1 Time in 1 Post
Re: Styling the <h1> tag.

oh right, so it's not some idiosyncrasy you have or something... lol

Not being that much of a geek, I didn't know that...lol
Last Blog Entry: Annoying people.... (Jan 16th, 2008)
Reply With Quote
  #8 (permalink)  
Old Jul 28th, 2006, 15:30
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,948
Blog Entries: 1
Thanks: 0
Thanked 29 Times in 29 Posts
Re: Styling the <h1> tag.

LOL well yeah. It is something I picked up a long time ago from hanging out on various web design/dev and programming channels on IRC.
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #9 (permalink)  
Old Jul 28th, 2006, 15:56
Highly Reputable Member
Join Date: Aug 2005
Location: 3rd Branch Up, Old Oak.
Age: 48
Posts: 658
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Styling the <h1> tag.

Quote:
"A metasyntactic variable is a placeholder name, or a kind of alias term, commonly used to denote the subject matter under discussion, or a random member of a class of things under discussion. The term originates from computer programming and other technical contexts, and is commonly used in examples by hackers and programmers. The use of a metasyntactic variable is helpful in freeing a programmer from creating a logically named variable, although the invented term may also become sufficiently popular and enter the language as a neologism. The word foo is the canonical example"
Demmit!
I didn't need the dictionary before you explained it!
Reply With Quote
  #10 (permalink)  
Old Jul 28th, 2006, 16:01
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,948
Blog Entries: 1
Thanks: 0
Thanked 29 Times in 29 Posts
Re: Styling the <h1> tag.

LOL I think we got way off topic. *hides*
__________________
I hate IE 6. Just sayin....
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
  #11 (permalink)  
Old Aug 14th, 2006, 10:12
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Styling the <h1> tag.

I do that on a lot of my sites like this:

HTML: Select all
<style type="text/css">
    h1 {
        width: 300px;
        height: 100px;
        margin: 0;
        text-indent: -5000px;
        background: #fff url("logo.jpg") no-repeat 0 0;
        display: block;
    }
</style>
<html>
    <h1>My Hidden Header Text</h1>
</html>
Reply With Quote
Reply

Tags
styling, lth1gt, tag

Thread Tools

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
help with styling my blog please alexgeek Website Planning 12 Sep 23rd, 2007 01:25
CSS border styling RZX Developer Web Page Design 6 Aug 10th, 2007 14:25
<HR> Styling RZX Developer Web Page Design 18 Jul 31st, 2007 22:15
RSS Styling question Daniel Other Programming Languages 4 Apr 8th, 2007 00:28
Styling up with CSS gwx03 Webforumz Suggestions and Feedback 10 Oct 14th, 2003 20:21


All times are GMT. The time now is 16:16.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43