• Resolved Rubenzella

    (@rubenzella)


    Hi guys, I am working on a child theme based on the default twentyeleven theme.

    I would like to replace the search box that is placed inside the header with a text area where write some contact details.

    The website I am actullay working on is http://antoniords.hostzi.com/RDS/

    Any suggestions?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Michael

    (@alchymyth)

    edit header.php and locate the code for the search bar –

    <?php
    				// Has the text been hidden?
    				if ( 'blank' == get_header_textcolor() ) :
    ...
    ...				<?php get_search_form(); ?>
    			<?php endif; ?>

    replace it with your data;
    you will need to wrap the new data into a div with unique css class to be able to format it properly.
    use the formatting and positioning of #searchform as a guideline.

    Thread Starter Rubenzella

    (@rubenzella)

    thank for your reply.

    I replaced that code with this
    <div class="searchform">
    Text Area
    </div>

    but even working with CSS I couldn’t move the text from where it actually is.

    I guess I did something wrong…

    Michael

    (@alchymyth)

    #searchform is a css id;

    either set your div to:
    <div id="searchform">

    or try to style:
    .searchform { ... }

    Thread Starter Rubenzella

    (@rubenzella)

    it was enough to change the div from class to id.
    In the CSS #searchform allows me to style the content.

    thank you!!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to replace the search box with a text area’ is closed to new replies.