Want to know when there are new posts?

SUBSCRIBE VIA EMAIL

SUBSCRIBE VIA RSS

Aug 19th

CForms II – More on Using as a Comment Form

Topics: All Things Wordpress Blogging

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.

Troubleshooting

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">
    <li>
    Comment Here
    </li>
    </ol>
    }

    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.

Tags: , , , , ,



RSS Feeds

MiniSitePacks.com

95% Of Your Minisite Design Done For You--INSTANTLY?

This is a complete solution! We're Talking Full Blown Graphics--From Top To Bottom--At A FRACTION Of What You Would Pay A Designer! Find out more.

Related Posts

74 Responses to “CForms II – More on Using as a Comment Form”


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

    Blog Post: Taking a break!

  2. Susan says:

    Reply

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

    Blog Post: Royale Blue

  3. Brandon says:

    Reply

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

  4. Andi says:

    Reply

    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

    to

    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.

    • ol id=”commentlist”

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

  5. Very interesting read.

  6. This is what I was looking for. Thanks.

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

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

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

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

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

    • Cforms has a support forum if you need more info.

      CForms Forum

      • Y says:

        Reply

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

      • Y says:

        Reply

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

        • 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.

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

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

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

  14. Jeremy says:

    Reply

    Do you take donations here ? Thank You

    • 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 gmail.com :-D

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

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

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

  18. Mark says:

    Reply

    Enjoyed your site! =)

  19. Awesome Article I enjoyed reading it :)

  20. Designer says:

    Reply

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

  21. blogg says:

    Reply

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

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

  23. Marc says:

    Reply

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

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

    • 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 :)

  25. Your instructions were very clear & concise.

    This should be very helpful for my Blog.

    Thank you

    -Josh

  26. Steven says:

    Reply

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

  27. Ubuntu says:

    Reply

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

    Blog Post: AutoScan Network, Network Monitoring and Management Tool

  28. 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.

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

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

  30. Viruster says:

    Reply

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

What Do You Think?

Enter your name as YourName@YourKeywords and YourKeywords will be used as the anchor link to your website. Psst this gives you Page Rank advantage.

  1. (required)
  2. (required)
  3. (required)

Comment Preview:

Just in case you wanna see.

You can also subscribe to comments via RSS Comments RSS