I have the following line
<select style="appearance:none;background-image:url('');" disabled>...</select>
to erase the right "down arrow" of the select box so that it looks like a disabled text box but has the select-option functionality which is manipulated via javascript.
This comes from one of the answers in this post: How to remove the default arrow icon from a dropdown list (select element)? and it is the only answer that works for me (I need it to be inline and not requiring additional library).
However in PHPStorm, it shows an error cannot resolve file ''
which makes me think this is not the proper way to specify an empty image via url()
.
I have tried this
appearance:none;background-image:url('data:')
which indeed eliminates the PHPSTorm error and works but it does not "look right" either. I would like to know the proper way to do this.
CodePudding user response:
have you tried the following?
<select style="appearance:none;background-image: none;" disabled>...</select>