Your address will show here +12 34 56 78

Home Forums WP ESTATE – Real Estate WordPress Theme FORUM Remove placeholder text on click

This topic contains 2 replies, has 2 voices, and was last updated by  Roxana 2 years, 8 months ago.

  • Author
  • #103642


    Hi, we really need some sort of onfocus event added to the advanced search text fields, so that the default value disappears when users click inside. It looks quite untidy when you click into the text box and the default value (such as “Max. Price”) stays there until you start typing. I tried adding an onfocus event to the fields in shortcodes.php but I can’t get it to work, any suggestions would be appreciated.


  • #103643



    I was able to achieve this with pure CSS by adding this to style.css:

    input:focus::-webkit-input-placeholder { color:transparent; }
    input:focus:-moz-placeholder { color:transparent; } /* FF 4-18 */
    input:focus::-moz-placeholder { color:transparent; } /* FF 19+ */
    input:focus:-ms-input-placeholder { color:transparent; } /* IE 10+ */

    It won’t work on older browsers but it works fine on the ones I have tested.

    I still think an onfocus event added to the template would be a better solution, maybe something for the next release?

    • This reply was modified 2 years, 8 months ago by  glauco.
  • #103663


    Hi Glauco,

    Thank you for your messages.

    We understand what you wish.
    We will add this on our review list for a future update.

    Thank you,

You must be logged in to reply to this topic.