WordPress.org

Ready to get started?Download WordPress

Forums

Accessibility of Search Box. (3 posts)

  1. emmadw
    Member
    Posted 8 years ago #

    I've just been checking threads that I've posted to in the past, one useful one "Lesson: Webpage Design & Accessibility" - which had a link to http://www.silktide.com/ made me think that I ought to check the page for accessibility. Most of my errors were easily fixable, other than the one that I got for the search box, which said that it didn't have a label. It doesn't - fair enough.

    However, I wasn't sure where to put the label, as following the instructions on WebAim, I tried in various places in the searchform.php code. (I'm using an edited Kubrick theme, but that page hasn't been edited). In general, I got the label I put in to show (which I didn't really want), however, I clearly wasn't getting it in the right place as the number of errors went up by 1 - i.e. the box still didn't have a label, and to add to that, I now had a label with no box!

    My blog is http://www.tech.port.ac.uk/staffweb/duke-wie/blog/ - (Those Feed2podcast logos are throwing errors for the Javascript behind them but I'm thinking of scrapping them, as I'm not that impressed anyway!)

  2. dutch_gecko
    Member
    Posted 8 years ago #

    Stealing from the old Classic theme, I have this:
    <li id="search">
    <label for="s">Search:</label>
    <form id="searchform" method="get" action="/index.php">
    <div>
    <input type="text" name="s" id="s" size="15" />
    <input type="submit" value="Search" />
    </div>
    </form>

  3. emmadw
    Member
    Posted 8 years ago #

    That looks so like what I did (that didn't work) that I think I must have done something wrong! I'll try again, as someone somewhere else has suggested a more or less similar bit of code.

Topic Closed

This topic has been closed to new replies.

About this Topic