The right look but is it semantic?

This is a discussion on "The right look but is it semantic?" within the Web Page Design section. This forum, and the thread "The right look but is it semantic? 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 Dec 16th, 2007, 18:59
konnor5092's Avatar
SuperMember

SuperMember
Join Date: Feb 2007
Location: Norwich, UK
Age: 23
Posts: 74
Thanks: 0
Thanked 0 Times in 0 Posts
The right look but is it semantic?

Maybe what I have done is okay but semanticly it could be poor.

I have the front page of a site I'm working on here....

http://www.mattoconnor.co.uk/index2.php

The code I'm concerned about is the header

Code: Select all
<div id="header">
        <h1>Team bullet proof bomb</h1>
        <h2>| competing | <span class="grey">in</span> | the |</h2> 
        <div id="navigation">
            <ul>
                <li><a href='index2.php'>home</a></li>
                <li><a href='about.php'>about</a></li>
                <li><a href='services.php'>services</a></li>
                <li><a class="last" href='portfolio.php'>portfolio</a></li>
            </ul>
        </div>       
    </div>
Code: Select all
#header, #middle, #bottom {
    width: 608px;
    margin: 0 auto;
}

/****** HEADER******/

#header {
    background: #000000 url(images2/bulletprooflogo.jpg) left center no-repeat;
    height: 149px;
}

#header h2 {
    background: url(images2/mongoliarally.jpg) 70% 48% no-repeat;
    height: 90px;
    padding: 20px 0 0 238px;
    font-size: 14px;
    font-weight: normal;
}
A couple questions..

- Should I have the logo within the <h1> tag? or is it okay as a background to the whole header?

- How can I write semantic code for the <h2> tag whereby 'competing in the mongolia rally' is within the <h2> but a logo is substituted for the mongolia rally and positioned as shown on the webpage?

Many thanks in advance.
Reply With Quote

  #2 (permalink)  
Old Dec 16th, 2007, 19:34
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

For the logo, I would simply use this:

Code: Select all
<h1><img src="logo.xxx" alt="Team bullet proof bomb"></h1>
The <h2> should not be interrupted by the | dividers (this is incredibly annoying for screen readers), and it should have the full text. Use this:

Code: Select all
<h2><span>competing</span><span>in</span><span>the</span>
<img src="MongoliaRally.xxx" alt="Mongolia Rally"></h2>
The spans are only necessary because of your line divider effect (the | glyphs). Personally I would dump the dividers, but if you want to keep them, apply them as background images to the spans.

Alternatively, make the entire <h2> into an image, and use the same method as for the <h1>. This would be easier.

Last edited by MikeHopley; Dec 16th, 2007 at 19:38.
Reply With Quote
  #3 (permalink)  
Old Dec 17th, 2007, 15:15
Aso's Avatar
Aso Aso is offline
Chief Moderator

SuperMember
Join Date: Oct 2007
Location: UK
Posts: 1,011
Blog Entries: 2
Thanks: 5
Thanked 23 Times in 20 Posts
Send a message via Skype™ to Aso
Re: The right look but is it semantic?

Matt, I see you've used
Code: Select all
 text-indent: -5000px
on your <h1> tag. Adding to that, set it to display:block and the height of your logo, then set the background of the <h1> element as the logo. Then do the same for the Mongolia Rally (and make an image that is the entire 'competing in the Mongolia Rally.')

Personally, I don't like images in header tags, and essentially the logo is presentation, not content. I must admit the Phark Technique (mentioned above) will suffer from CSS On / Images Off scenario, whereas Mike's suggestion will mean the alt tag is at least visible.

You might also want to read about FIR (Fahrner Image Replacement), but IMO it has no advantages over Phark (and requires extra markup)
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
Reply With Quote
  #4 (permalink)  
Old Dec 17th, 2007, 15:22
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

I don't see the problem with images in headings.

If you've decided that you prefer users to see the image, then why not put it straight into the heading? This is the most straightforward and logical way, and it avoids all possible accessibility problems (provided you use alt text).

All the "clever" alternatives involve potential accessibility problems.

Search engines can (and do) index alt content.

If the logo is being used to communicate a page heading, then it is not presentation. It's content. It happens to be content conveyed by an image, but it's content nonetheless.

Last edited by MikeHopley; Dec 17th, 2007 at 15:27.
Reply With Quote
  #5 (permalink)  
Old Dec 17th, 2007, 15:29
welshstew's Avatar
Lead Administrator

SuperMember
Join Date: May 2007
Location: inside the outside
Posts: 1,388
Blog Entries: 13
Thanks: 1
Thanked 17 Times in 15 Posts
Re: The right look but is it semantic?

Quote:
Originally Posted by aso186 View Post
You might also want to read about FIR (Fahrner Image Replacement), but IMO it has no advantages over Phark (and requires extra markup)
You can also look at the Gilder / Levin method:

http://www.mezzoblue.com/tests/revis...e-replacement/ - near the bottom

http://wellstyled.com/files/css-repl...example02.html - example (header)

http://wellstyled.com/css-replace-text-by-image.html - look at second method

again, it requires a little extra markup, and also solves the CSS on / images off scenario. It also works with JAWs (screen reader software).
__________________
WelshStew
Lead Administrator

tierney rides tboard - uk site | xtreme wales - extreme clothing
If you think I've helped, click the "Thanks"
webforumz - facebook | LinkedIn
Last Blog Entry: Web Standards Curriculum Launched (Jul 8th, 2008)
Reply With Quote
  #6 (permalink)  
Old Dec 17th, 2007, 15:49
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

Were I to use an image replacement technique, it would be Gilder/Levin. That's the only one that seems even close to sane.
Reply With Quote
  #7 (permalink)  
Old Dec 17th, 2007, 16:28
konnor5092's Avatar
SuperMember

SuperMember
Join Date: Feb 2007
Location: Norwich, UK
Age: 23
Posts: 74
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

cheer chaps.

I'll give that a whirl.
Reply With Quote
  #8 (permalink)  
Old Dec 17th, 2007, 20:09
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

PPK's javascript version is another sane option.
Reply With Quote
  #9 (permalink)  
Old Dec 18th, 2007, 15:48
karinne's Avatar
SuperMember

SuperMember
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

There's also the Rundle text-indent method which I really like

How do I hide text but still have my site accessible to all?
Reply With Quote
  #10 (permalink)  
Old Dec 18th, 2007, 16:25
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: The right look but is it semantic?

Quote:
Originally Posted by karinne View Post
There's also the Rundle text-indent method which I really like

How do I hide text but still have my site accessible to all?
Better than most, but the text is inaccessible for visual browsers with images off.

So a better title would have been: "How do I hide text but still have my site accessible to some?"
Reply With Quote
Reply

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
Web Semantic Role - Contract - Prototyping, .net patrickbradley Job Opportunities 0 Mar 7th, 2008 11:56


All times are GMT. The time now is 07:11.


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