IN Wordpress Plugins

CForms II – More on Using as a Comment Form

posted Tuesday, August 19th, 2008

Good news! There is a new version of CForms that is out and has got great features. The best thing about it is it has got most of the features on my wish list :)

So here goes…

Plugin Compatibility

CForms is now completely compatible with three of the most used comment plugins.

First Step is to install the above mentioned plugins and activate them.

Next… adding Subscribe To Comments and CommentLuv

When you add the comment form you will notice two extra fields: Subscribe To Comments and CommentLuv. Adding these will make sure that the two plugins now work seamlessly with CForms. Yes it really is that simple!

And … WP AJAX Edit Comments
This is the simplest one to work with as all you need to do is upgrade to the latest version of this plugin. The plugin authors of both CFORMS and WP AJAX Edit Comments have worked together to make sure the plugins are compatible. So hats off to them.

Comment Template

When you post a comment using the CForms comment form, you might not get to see the comment posted until you refresh the page. This is because there is one last setting that needs to be adjusted.

  1. Click global settings.
  2. Next select ‘WP Comment Feature Settings’
  3. The most important setting here is ‘Parent Comment Container’. Your comments are wrapped in an ol tag. Whatever id is set for that must be added to this field. Example:

    <ol id="commentlist">

    In this case the ‘Parent Comment Container’ will be ‘commentlist’

  4. Next we design the look of the comment template to match the one in comments.php. This can be done under ‘New comment HTML template’. If you click on Supported Variables you will see a list of all that you can use. The good news is that there is now a gravatar option. Also if you use the Default Template as the starting point, it also has the option of alternating the class.

    <li class="alt" id="comment-{id}">

  5. Lastly you can also set the gravatar size to your liking.

You should now be able to preview your comment without re-loading te page plud have the option of editing it if yo are using the WP AJAX Edit Comments plugin.


There are some problems you might run into.

  1. You might note that your first comment needs refreshing while the follow-up comments can be easily viewed without a reload.

    There is a reason. Your most probably have your comment code like this:

    If Comment {
    <ol id="commentlist">
    Comment Here

    Note that the ol tag is only displayed if there is a comment. Your blog doesn’t know there is a first comment until the page is re-loaded. Since the ol tags are not used, CForms cannot show the comment. If you have them outside the ‘if comment’ and the ol tag is rendered regardless of whether there is a comment or not then Cforms can work its magic.

  2. You might find that you can no longer access your WordPress admin or that pages go blank after you save settings. Check to make sure that cforms.php in your plugins/cforms folder does not have any empty spaces at the end. If the problem persists, then it can be a PHP memory issue. This can be set in your php.ini file if you run your own server or you can ask your host to increase PHP memory to say 32 or 64.

Enjoy the new version of CForms … I’m sure this plugin will continue to improve. In which case there will be a part 3 to this tutorial someday.

  • Andy Bailey

    excellent tutorial! nice to see how easily commentluv and subsribe to comments are added to this great form

    Blog Post: Taking a break!

  • Susan

    Great to know, since this is one of my more favorite plugins.

    Blog Post: Royale Blue

  • Brandon

    Thanks for the info, just what I was looking for. Very innovative site by the way.

  • Andi

    I got all set and working (like mail), except for the comments to show up. I have read the faq and the tutorials and still have to ask someone:

    1. I changed wordpress comments.php from


    2. Set “mycommentcontainer” in cformsII global settings.

    3. the template id=”comment-{id}” should match the actual one. i tried all kinds of possible id’s from my theme’s comment.php and cformsII forms… Can you tell me, if it’s comment-{2} or evencomment-{cform2form}?

    I am quite familiar with php, but here I got something completely messed up?!?! Thanx for your advice.

  • Erum Munir

    ol id=”commentlist”

    This is the ID that needs to match in both your comments.php and cforms comment container.

  • Henry Masterson

    Very interesting read.

  • Susan Marcens

    This is what I was looking for. Thanks.

  • Amy Denver

    Thanks a lot for this. I will recommend your blog to my friends.

  • David Coleman

    Would you mind if I add this article to my blog? By providing credit and link ofcourse.

  • Kevin Deboer

    I just find your blog. I must say that it is very good read. I will recommend it to my friends.

  • Carol Sanderson

    I would like to get further information on this. You gave a lot of good points but there are still missing parts.

  • Erum Munir

    Cforms has a support forum if you need more info.

    CForms Forum

  • Hot Penny Stocks

    Great article I will be back in a couple day to see others posted. Also nice site I really like the template you have.

  • seo essex

    Great post as always. You should really make a career outta this ;)

  • Jamie Hunt

    Thanks so much for the resource, I have found it quite useful and have bookmarked your site!

  • Jeremy

    Do you take donations here ? Thank You

  • Erum Munir

    I”ve been meaning to install the donations plugin for WP. But if anyone’s interested in the meanwhile my Paypal email is emunir at :-D

  • Erum Munir

    David, Thanks for asking. But I’d rather not have the article copied elsewhere. You are welcome to link to it, though :)

  • Jon kline

    I enjoyed reading your post and really like your style. I have bookmarked for future visits …. Keep up the good work

  • Mephit322

    Excellent post. I’m enjoying your blog, going to subscribe! :)

  • Aaron Benson

    I enjoyed reading this article. It seems that you are a great source of information. Keep them coming.

  • Y

    Just checking if cforms work with wp2.7 threaded comments…

  • Y

    Erum, it seems to work.. have you modified cforms to work? Now cforms posts only “depth-1″…

  • Mark

    Enjoyed your site! =)

  • xSubZer0x

    Awesome Article I enjoyed reading it :)

  • Designer

    This is great article. Thank you, and I will forward to all my freinds.

  • blogg

    I really liked your blog!will chck back soon again thx

  • Fun Director

    Can you tell me who did your layout? I have been looking for one kind of like yours. Thank you.

  • Erum Munir

    Thanks! Glad you like the layout :) I designed it myself. My design website is DotsnDashes Website Designs

  • Marc

    Please keep up the good work.. I enjoy reading your thoughts.

  • Josh Patrone

    Pretty nice… Hope you can write more, so I can read more!

  • missouri forums

    Your instructions were very clear & concise.

    This should be very helpful for my Blog.

    Thank you


  • Steven

    Where is the best place to learn about this? This is a good article, thanks :D

  • Ubuntu

    Nice blog post,i found this blog at yahoo and i like it.

    Blog Post: AutoScan Network, Network Monitoring and Management Tool

  • Mikrodalga Tarifleri

    I am reading your blog posts for a long time and this is my first comment at your blog because i like the post :) Please keep it up.

  • Erum Munir

    I’m not the author of Cforms … I have just written this tutorial to help people who want to use the plugin.

    The plugin author updates the plugin regularly and makes sure it is up to date with the latest WP version.

  • Erum Munir

    Thanks! I do plan on writing more soon. Just been very busy with some personal stuff lately. But I am going to get back to this blog :)

  • Erum Munir

    You can learn more at the Cforms Forum.

  • Erum Munir

    Thank you so much! :) Really glad to hear that.

  • Samantha J.White

    Cool post, i have subscribed to your blog.Please keep it up, Samantha

  • Viruster

    Thank you very much for the info, very informative and useful. I will add this to my collection of cool sites! Thanks again!

  • Jack Avisos

    Thanks alot for this information !!! Keep in the road !

  • Government Loan Modification Program

    Nicely said, I enjoy the time that it took to research and write. Great work.

  • Roxana Trabajo

    Hey, i was seeing a leng in squidoo, then take me to another link that leave me here, it is a great post dude, thanks !

  • SubmitterWeb

    I have read a few of your posts and they are all interesting and informative…keep up the good work.

  • Paul

    Excellent blog, thanks for all the hard work. Subscribed to feed :)

    Blog Post: Personal Finance Rules for Dummies

  • jack parler

    Nice post. Thanks for sharing these tips.

  • Julie Straus

    I readed several posts of your blog, but never taked the time to say thank you. Just that.


  • ziben

    Great Post!!!
    Doyou know how to change default comment field box
    Using cformsII. ?

    Anyway txx

  • Good Directory

    I searched on google and I had a hard time located the right info….until I found your blog.

  • SEO Optimizer

    It was great to go through the stuff posted on your blog. Look forward to more useful posts in future.

  • Erum Munir

    If you use an RSS reader just go to this link:

    Or if you prefer to subscribe to the RSS feed via email, then just add your email in the top bar where it asks you to subscribe.

  • Paul Daniel

    I Love your blog on google and have read many of your posts. Excellent. Keep up the good work!!!

  • markus hansen

    Whattadya know, another site to add to my reader! Google blog search has you pretty well indexed! Mark

  • chandler

    Keep up the good work. Look forward to reading more from you in the future.

    Blog Post: Weight Loss Pills – Unique Hoodia

  • Alesha

    What an inspirational post. It’s great to see some unique content and interesting read for once. There is too much rubbish cycling around on blogs now, so keep up the great work!

    Blog Post: The Pentax Optio E70 Digital Camera Receives the Thumbs Up From Internet Users

  • william ellis

    Great site and great information too, do you use twitter?

  • moue

    More visitors will come if more interesting and informational topics keep being posted. :)

  • Gabby

    Blogger has finally come up with the inline comment form.. nice to see more and more features getting added to blogger..I have also added the old comment form in my blog..

    Blog Post: How To Select Right Cage For Your Bird

  • Erum Munir

    Yes I do. You can follow me at Twiiter

  • Erum Munir

    I intend to. Just gotten super busy with clients and projects. I will start posting again, soon.

  • james

    I am having problems getting the autoload to work correctly, any ideas or changes in new versions of cforms? Do you need wp ajax edit comments to get autoload to work correctly?

  • Fabian

    Can you explain to me how to do this example: but only to add a text field to be printed with the same info that the user types in the box in WP.

    I have the following problem:

  • Charles@Las Vegas Properties

    CForms are great. I so need to update to the latest version. Its one of the things that I keep hoping will be in the next WP upgrade as a standard option.

  • Selvam@Vamban News Blog

    Cforms is 5 star rated pluign among all other wordpress plugins. Really great work there :)

  • vynsynt

    Thanks a ton for the helpful article!

    Do you know if there’s an easy way to suppress comments from displaying on a page until AFTER they’ve been approved?


  • Pedro

    Hi, thanks for your post. Do you know if there are any issues with cform on wordpress running in a Windows Server? I’ve configured the plugin as comment form in a Linux server and it worked perfecly, but in Windows the form get stucked.

  • Abraham

    I’m having this exact problem – new comment will not post until you refresh the page. It’s very frustrating and I’m sure it will frustrate readers. Unfortunately your advice in this post is a little over my head. Can you dumb it down at all? Possibly identifying exactly what to do with the ol tag step by step?

    (p.s. the website is:

  • Erum Munir

    This is a WordPress setting for discussion. You can set up moderation there. Settings – Discussion

  • Erum Munir

    Sorry, I have idea about the Windows server. You will need to ask the plugin author.

  • Susan@New WordPress Themes

    I like this plugin…it’s more lightweight than a few other contact plugins.

  • Brian

    Forms like this add great functionality to your site and allow you to get important feedback from the people who should matter the most, your customers.

  • ATV Parts

    Is this adaptable to all blogs or do you have to have a certain theme to add it to your blog?

  • Erum Munir

    It can be used with any theme as long as all the basic hooks are there.

  • F Esayas

    i saw your post and i wanna say you thank you for your posts and for this nice blog.keep it up.

  • ent surgeon

    it is more than i expected.great job!!!

blog comments powered by Disqus