WordPress.org

Ready to get started?Download WordPress

Forums

Search Form button not working (9 posts)

  1. eight20
    Member
    Posted 5 years ago #

    My search form seems to be working fine when you type a word in and hit enter. But if you were to hit the "go" button seen below, it just refreshes the page you are on. What code needs to go inside the (a href="") to make that button do the search?

    <div class="mitemr"><a href="">Go</a></div>
    <form method="get" id="searchform" action="<?php bloginfo('url'); ?>/">
    <input type="text" class="searchbox" name="s" id="s" />
    <input type="submit" id="searchsubmit" value="Search" style="display: none;" />

    Thanks.

  2. You need to use the form input submit type to do anything. You're href is empty and, therefore, going no where.

    Remove the style="display: none;"

  3. eight20
    Member
    Posted 5 years ago #

    the whole point of that is to not have a physical click button, rather the word "go" be the clickable executor. if i remove the style display none, it will show the oval looking button.

  4. You do know you can style that button to look like you want it to with CSS, right?

  5. eight20
    Member
    Posted 5 years ago #

    i didn't know that, otherwise i probably would have done it. if you or someone else could help with that coding, i'd appreciate it.

  6. #searchsubmit{
    cursor:pointer;
    background:none;
    border:0;
    }
    #searchsubmit:hover{
    border-bottom:1px #000000 solid;
    }

    Customize to your tastes.

  7. eight20
    Member
    Posted 5 years ago #

    awesome. i'll try that out.

  8. eight20
    Member
    Posted 5 years ago #

    didn't really work right. anyone else?

  9. What about it didn't work?

Topic Closed

This topic has been closed to new replies.

About this Topic