locked
Placeholder in combo box / dropdown (HTML Client)... RRS feed

  • Question

  • Hello,

    Does anyone know how to change default placeholder text in combo boxes (HTML Client)? By default it says "Search", but I need to change it to different text.

    I've tried the following in postRender, but it doesn't seem to do anything. Surprisingly, the same code works fine with normal text box, which suggests problems with combo box only.

    $('input', element).attr('placeholder', 'Text goes here');

    Any suggestions would be greatly appreciated.

    Thank you very much in advance,

    Kind regards,

    Tom



    • Edited by l3ulky Monday, March 20, 2017 12:41 PM
    Monday, March 20, 2017 12:01 PM

Answers

  • Hello,

    Does anyone know how to change default placeholder text in combo boxes (HTML Client)? By default it says "Search", but I need to change it to different text.

    I've tried the following in postRender, but it doesn't seem to do anything. Surprisingly, the same code works fine with normal text box, which suggests problems with combo box only.

    $('input', element).attr('placeholder', 'Text goes here');

    Any suggestions would be greatly appreciated.

    Thank you very much in advance,

    Kind regards,

    Tom



    I've figured this out. The following code works fine:

    $('ul', $(element)).attr('data-filter-placeholder', 'Text goes here');


    • Edited by l3ulky Monday, March 20, 2017 1:57 PM
    • Marked as answer by l3ulky Monday, March 20, 2017 1:58 PM
    Monday, March 20, 2017 1:57 PM