I have tried multiple solutions from various sources, but nothing seems to be working. My goal is to apply the fontawesome icon f14a to a specific field. What am I doing wrong?
document.getElementById('property_charges').setAttribute('class', 'fontawesome-placeholder');
document.getElementById('property_charges').placeholder = '&#f14a';
Here is the corresponding CSS:
.fontawesome-placeholder {
//padding:10px;
//font-family: FontAwesome;
//z-index: 9999;
//z-index: 1;
font: normal normal normal 14px/1 FontAwesome;
font-size: inherit;
text-rendering: auto;
}
The solution provided in the "duplicate" link isn't effective, and I prefer not to use JQuery in this project.