Forums

Have I put together the first XHTML Strict theme? (3 posts)

  1. Rocknation
    Member
    Posted 2 years ago #

    I doubt it--too many geniuses around here, LOL! But I have managed to find solutions to the problems I've had with XHTML Strict.

    Search and Latest Comments are the only default WP widgets that don't test as XHTML Strict compliant. Here is compliant search form code:

    <form method="get" id="searchform" action="<?php echo $_SERVER['PHP_SELF']; ?>">
    <p>
    <input type="text" value="<?php echo wp_specialchars($s, 1); ?>" name="s" id="s" size="12" />
    <input type="submit" id="ssubmit" value="SEARCH" />
    </p>
    </form>

    Here is compliant flash/YouTube embed code:

    <object width="425" height="344">
      <param name="movie"
             value="http://www.youtube.com/v/dMH0bHeiRNg&hl=en&fs=1">
      </param>
      <param name="allowFullScreen" value="true"></param>
      <embed src="http://www.youtube.com/v/dMH0bHeiRNg&hl=en&fs=1"
             type="application/x-shockwave-flash" allowfullscreen="true"
             width="425" height="344">
      </embed>
    </object>

    And this javascript will allow you to target="_blank" (write rel="target_blank" instead):

    function externalLinks() {
      if (!document.getElementsByTagName && document.getElementById) return;
    
      var anchors = document.getElementsByTagName("a");
    
      for (var i=0; i<anchors.length; i++) {
       var anchor = anchors[i];
       if (anchor.getAttribute("href") &&
           anchor.getAttribute("rel") == "target_blank")
           anchor.target = "_blank";
     }
    }
    window.onload = externalLinks;

    ProfitOnlineForBeginners.com is still in the planning stages. But the theme I put together tests as Strict compliant--even with a fluid center column!

  2. MAzCastro
    Member
    Posted 2 years ago #

    As a "touché" to you, I have validated WP sites with AAA acessibility conformance level.

    MAC :)

  3. esmi
    Theme Diva & Forum Moderator
    Posted 2 years ago #

    @Rocknation: I only develop with valid XHTML Strict. :-)

    @FMacastro: AAA? Really? WCAG 1.0 or 2.0?
    Urls?

    Bear in mind that I'm part of Team Access at Accessites - so I'm well used to assessing sites for accessibility. I also take AAA claims with a huge pinch of salt. In my experience, only about 1 in 100 claims is actually valid. Care to take the challenge? Or even better, submit one of your sites to Accessites? :-)

Topic Closed

This topic has been closed to new replies.

About this Topic