Search form placeholder text - by bdcmc - on WordPress WooCommerce support

This topic has 4 replies, 3 voices, and was last updated 8 years, 7 months ago ago by Stan Russell

  • Avatar: bdcmc
    bdcmc
    Participant
    April 26, 2016 at 12:39

    hello, i want to change placeholder ‘search’ text to ‘i’m looking for…’ text

    i try to change…

    <form method="get" id="searchform" class="hide-input" action="<?php echo esc_url( home_url( '/' ) ); ?>">
    	<input type="text" name="s" id="s" placeholder="<?php esc_attr_e( 'Search...', ETHEME_DOMAIN ); ?>" />
        <input type="hidden" name="post_type" value="post" />
        <input type="submit" value="<?php esc_attr_e( 'Go', ETHEME_DOMAIN ); ?>" class="button" />
        <div class="clear"></div>
    </form>
    

    to

    <form method="get" id="searchform" class="hide-input" action="<?php echo esc_url( home_url( '/' ) ); ?>">
    	<input type="text" name="s" id="s" placeholder="<?php esc_attr_e( 'i'm looking for...', ETHEME_DOMAIN ); ?>" />
        <input type="hidden" name="post_type" value="post" />
        <input type="submit" value="<?php esc_attr_e( 'Go', ETHEME_DOMAIN ); ?>" class="button" />
        <div class="clear"></div>
    </form>

    code but it is not working. can you please get a look into this…

    3 Answers
    Avatar: Robert Hall
    Robert Hall
    Support staff
    April 26, 2016 at 13:10

    Hello,

    You should edit \wp-content\themes\legenda\framework\shortcodes.php file on line 195

    
    $output .= '<input type="text" value="'.$search_input.'" name="'.esc_attr($search_key).'" id="s" autocomplete="off" placeholder="'.__('Search', ETHEME_DOMAIN).'"/>';

    Regards,
    Robert Hall

    Avatar: bdcmc
    bdcmc
    Participant
    April 26, 2016 at 15:10

    its working perfectly..!! thank you. 🙂

    Avatar: stan
    Stan Russell
    Participant
    April 26, 2016 at 15:45

    Hello bdcmc,

    you are welcome!

    Regards,
    Stan Russell.

  • Viewing 4 results - 1 through 4 (of 4 total)

The issue related to '‘search form placeholder text’' has been successfully resolved, and the topic is now closed for further responses

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.