Support » Fixing WordPress » search widget duplicate

  • Resolved married2design


    Using a customized theme…has only one sidebar. I want to move the search widget from the header to the sidebar. I can add the search widget to the sidebar but can’t remove it from the header? Hard-coded I think but I am not sure how to get rid of it just in the header.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Christine Rondeau


    Volunteer Forum Moderator

    If it’s hard coded in the header.php, can’t you just edit that file?

    What’s the link to your site?

    where is the code that is placing the search widget in the header and what might it look like? in header.php? functions.php?

    when I use css it changes the appearance of both instance of the widget–ie float left or right. I can remove it from the sidebar but not the header. hmmm. I’m stuck.

    Christine Rondeau


    Volunteer Forum Moderator

    The one in the header is hard coded… You’ll need to edit the header.php file.. I think..
    In the html source, your header appears at the bottom?? Very strange, but I’m guessing your developer used the header.php.

    There should be some code that looks like this:

    <fieldset id="search">
            <span class="textfield">
                <input type="text" class="text" value="" name="s" id="s" />
            <span class="submit">
                <input type="image" id="searchsubmit" src="" alt="" />

    That’s the search box. Just delete that and you should be good.

    no such stuff in the header.php file–
    only thing I find is in
    <form method=”get” id=”searchform” action=”<?php bloginfo(‘url’); ?>/”>
    <fieldset id=”search”>
    <span class=”textfield”>
    <input type=”text” class=”text” value=”” name=”s” id=”s” />
    <span class=”submit”>
    <input type=”image” id=”searchsubmit” src=”<?php bloginfo(‘template_url’); ?>/images/bg-search-image-btn.gif” alt=”” />

    ooo oooh… then in the header I found this:
    <meta http-equiv=”Content-Type” content=”<?php bloginfo(‘html_type’); ?>; charset=<?php bloginfo(‘charset’); ?>” />

    <title><?php wp_title(‘«’, true, ‘right’); ?> <?php bloginfo(‘name’); ?></title>

    something to do with bloginfo???

    any ideas Christine? or anyone else?
    The searchform.php is being called to that top position by something–but what?

    solved!! It was in the footer.php just like you said–way at the bottom. Took me all day but fixed!

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘search widget duplicate’ is closed to new replies.