• eight20

    (@eight20)


    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.

Viewing 8 replies - 1 through 8 (of 8 total)
  • 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;"

    Thread Starter eight20

    (@eight20)

    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.

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

    Thread Starter eight20

    (@eight20)

    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.

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

    Customize to your tastes.

    Thread Starter eight20

    (@eight20)

    awesome. i’ll try that out.

    Thread Starter eight20

    (@eight20)

    didn’t really work right. anyone else?

    What about it didn’t work?

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Search Form button not working’ is closed to new replies.