Reputation: 603
I want to know how we can remove placeholders of contact form in divi theme by the the help of JavaScript. So that when someone open this contact form the placeholder does not show to user.
Upvotes: 2
Views: 3391
Reputation: 316
If placeholder inside in input tag, you just can only delete then.
Example, i have this tag:
<input type='text' id='some' name='some' placeholder='some text goes here' />
And you want remove the placeholder tag, you could just remove it deleting it, but if you want remove it after some action, you could easy use JQuery .removeProp() (the reference you could find here), that depends the theme you're using in wordpress instalation.
Can be used css to remove it.
Example:
::-webkit-input-placeholder { /* WebKit browsers */
color: #fff;
}
:-moz-placeholder { /* Mozilla Firefox 4 to 18 */
color: #fff;
opacity: 1;
}
::-moz-placeholder { /* Mozilla Firefox 19+ */
color: #fff;
opacity: 1;
}
:-ms-input-placeholder { /* Internet Explorer 10+ */
color: #fff;
}
You could share the website link and informe the section you want remove that placeholder(s)
Upvotes: 3