EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: arma on November 27, 2014, 09:15:19 AM



Title: Combobox Placeholder
Post by: arma on November 27, 2014, 09:15:19 AM
Hi,

Is there a way how to show some text in combobox, something like placeholder property when combobox not select any row.

Thanks.


Title: Re: Combobox Placeholder
Post by: arma on November 27, 2014, 09:46:28 AM
I got a workaround :

Code:
 $('#mycombo').combobox('textbox').prop('placeholder', 'Type product name here...');


Title: Re: Combobox Placeholder
Post by: jarry on November 27, 2014, 06:31:32 PM
The simplest way is to set the 'prompt' property.
Code:
<input class="easyui-combobox" style="width:200px" data-options="
    prompt:'Type product name here...'
    ">


Title: Re: Combobox Placeholder
Post by: arma on November 27, 2014, 08:53:47 PM
Ah, how could i miss this property. Thank you Jarry  ;)