A Guide to HTML Post Comments in WordPress

WordPress is great for blogs, and of course commenting is an essential part of blogging. Your blog readers can post comments with HTML tags. For their convenience, you can display a list of all allowed HTML tags in the comments form using the following PHP code in functions.php:

Change Allowed HTML Tags

You can also change what HTML tags are allowed in your comments form.

Edit functions.php (located in your wp-content/themes/ directory) and append the following code:

If you enjoyed this post, make sure to subscribe to WPMayor’s RSS feed.

About Jean Galea

Jean Galea is a WordPress developer, entrepreneur and padel player. He is the founder of WP Mayor, the plugins WP RSS Aggregator and EDD Bookings, as well as the Mastermind.fm podcast. His personal blog can be found at jeangalea.com.

Related Articles

10 Responses

  1. taper roller bearing
    taper roller bearing February 16, 2012 at 03:36 | | Reply

    ok,very goog thank you

  2. santa
    santa March 10, 2012 at 14:16 | | Reply

    Great blog.

  3. html color name
    html color name April 4, 2012 at 19:54 | | Reply

    great tutorrials are shared thanks for this
    html color name

  4. WPAchiever
    WPAchiever February 15, 2013 at 04:15 | | Reply

    I’ll try and see if it works…I hope I won’t mess up my theme’s functions.php CSS code 😛
    Thanks for the tutorial

  5. Santa?
    Santa? May 10, 2013 at 02:04 | | Reply

    This is helpful indeed.

  6. Mike Savag
    Mike Savag June 22, 2014 at 07:43 | | Reply

    Looking for a job as service provider? Post your skills to become a service provider. Hundreds of work categories including: Delivery – Cleaning – Recycling – Shopping – Handyman – Catering – Plumbing – Computer Help – Website Design – Writing – Tutoring – Pet Sitting – Child Care – Gardening

    Are you looking for permanent employment? Search over 1 million job listings. From executive jobs to temporary work

    Labor Bazaar Is A Social Network Driven Labor Marketplace

    Visit: Laborbazaar.com

  7. chetaru
    chetaru July 1, 2014 at 10:06 | | Reply

    nice job…exatly was searching fr the same…

  8. emma
    emma December 1, 2014 at 12:13 | | Reply

    than you for this code. I am finding this one. best coding site

  9. cubedcherry- Michael Steyn
    cubedcherry- Michael Steyn December 24, 2014 at 17:42 | | Reply

    Excellent! This post have just solved my problem. Thank you kindly!

  10. Lex Mark Clavaton
    Lex Mark Clavaton April 27, 2017 at 07:55 | | Reply

    Yes, But if you are looking where to advertise your business online, I have an online to tool to introduce, the iConnect10 – wherein you can build your business, and get paid!!

Leave a Reply