SitePoint Sponsor

User Tag List

Results 1 to 11 of 11
  1. #1
    I meant that to happen silver trophybronze trophy Raffles's Avatar
    Join Date
    Sep 2005
    Location
    Tanzania
    Posts
    4,662
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)

    <address> - for phone no. and email?

    I was going through a website I made last year cleaning it up and put some <address> tags around an address instead of a blockquote. Then I came across the email address and phone number and pondered what to do. In the end I put them in address elements too - is this acceptable or wrong? It seems like a bit of a grey area to me.

  2. #2
    CSS & JS/DOM Adept bronze trophy
    Join Date
    Mar 2005
    Location
    USA
    Posts
    5,482
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    We miss you, Dan Schulz.
    Learn CSS. | X/HTML Validator | CSS validator
    Dynamic Site Solutions
    Code for Firefox, Chrome, Safari, & Opera, then add fixes for IE, not vice versa.

  3. #3
    SitePoint Wizard bronze trophy Tailslide's Avatar
    Join Date
    Feb 2006
    Location
    Bedford, UK
    Posts
    1,687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    To my knowledge the address tag is reserved for the contact details of the author of the page rather than necessarily contact details for the company/site - if you see what I mean by the difference!
    Little Blue Plane Web Design
    Blood, Sweat & Rust - A Land Rover restoration project

  4. #4
    I meant that to happen silver trophybronze trophy Raffles's Avatar
    Join Date
    Sep 2005
    Location
    Tanzania
    Posts
    4,662
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    These are contact details for the author and general "person to contact" about the project, so I would assume putting it around telephone and email is ok then. Since there appears to be no concrete consensus on <address>, I'll do it.

  5. #5
    SitePoint Author silver trophybronze trophy

    Join Date
    Nov 2004
    Location
    Ankh-Morpork
    Posts
    12,158
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ADDRESS is for contact information. It may be a postal address, but it might also contain telephone numbers, email addresses, directions for homing pigeons or whatever.

    The most common misuse of ADDRESS is to use it to mark up any postal address, i.e., even those that dont' specify contact information for the page or site.
    Birnam wood is come to Dunsinane

  6. #6
    I meant that to happen silver trophybronze trophy Raffles's Avatar
    Join Date
    Sep 2005
    Location
    Tanzania
    Posts
    4,662
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Thanks. Now I'm wondering whether this is bad:
    HTML Code:
    <address>
    Joe Bloggs<br />
    Street<br />
    Town<br />
    Country
    </address>
    <address><strong>Telephone:</strong> 123456789</address>
    <address><strong>Email:</strong> joe@bloggs.com</address>
    Which is convenient so I can specify margins between the address elements. But I suspect I should be putting it all in a single <address> element. Should I?

  7. #7
    SitePoint Author silver trophybronze trophy

    Join Date
    Nov 2004
    Location
    Ankh-Morpork
    Posts
    12,158
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I think it should be in a single ADDRESS element; it doesn't make semantic sense otherwise.

    You can enclose parts of the contact information i SPAN elements to provide styling. Your use of STRONG seems a bit odd. Why would you like the word 'Telephone' to be pronounced with strong emphasis, but not the actual telephone number? It looks like <b>Telephone&#58;</b> would be more appropriate, if you are only looking for visual rendering.
    Birnam wood is come to Dunsinane

  8. #8
    Caveat surfer Buddy Bradley's Avatar
    Join Date
    May 2003
    Location
    Cambridge, UK
    Posts
    2,366
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    And if you're going to add SPANs to those elements, don't forget the vcard microformat!

  9. #9
    I meant that to happen silver trophybronze trophy Raffles's Avatar
    Join Date
    Sep 2005
    Location
    Tanzania
    Posts
    4,662
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Cheers guys. Not sure about the microformat (hCard it's called on microformats.org), seems a bit like overkill. Unless you can show me anyone/anything that uses it.

  10. #10

  11. #11
    I meant that to happen silver trophybronze trophy Raffles's Avatar
    Join Date
    Sep 2005
    Location
    Tanzania
    Posts
    4,662
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    OK you win. But I do wonder, as it says there, do google and yahoo really understand and read and use microformats like hCard?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •