How to Remove HTML Tags from WordPress 3.x Comment Box


This tutorial is going to guide you how to get rid of the html code under the message box in the WordPress twenty ten’s comment template.
First a warning, do not edit or delete the code from WordPress 3.x core files, instead hide it with CSS code.
  • Using CSS has the advantage of not requiring core file modifications (always a bad idea).
Put simply, you need to add the following line of code to the your Theme style sheet.
.form-allowed-tags { display:none; }
So, using the WP Twenty ten theme as an example, here are the steps:
1. Login to your WordPress dashboard
2. Go to Appearance/Editor.
3. Open the stylesheet file, style.css. It will be listed at the bottom of the right-hand column.
4. Go to the end of the style.css style sheet and enter the code on a new line:
.form-allowed-tags { display:none; }
5. Save the file (Update File button) and you’re done.
6. And that’s all there is too it. If you now inspect your comment box the offending HTML Tags will have gone.

Comments

Popular posts from this blog

8 Best CMSs for building a well structured social networking website

Manor House - Telscombe Village