Design and CSS styles
Version 5.x > Design and CSS styles > Blog Post Comment Form View modes: 
User avatar
Member
Member
kelements - 2/28/2011 2:19:25 PM
   
Blog Post Comment Form
I am trying to style the Comment form that appears under each blog. I see that it is set up in a table. Where is the working file for this table and how style it?

Also, how do I remove some of the form fields that are in the comments form by default. What I would like to do is have only the Comment box, then when the user clicks submit, the lightbox appears prompting the user to create a login for my site.

Here is an example on another site...
http://www.wonderhowto.com/wonderment/make-spoon-disappear-0125548/#contentComments

Type a comment and click "Add Comment", you will see the login prompt.

Thanks!

User avatar
Kentico Developer
Kentico Developer
kentico_ondrejv - 3/9/2011 1:39:37 AM
   
RE:Blog Post Comment Form
Hello,

You can adjust the blog post comment editing area layout in following file: ~\CMSModules\Blogs\Controls\BlogCommentEdit.ascx. You can amend it to suit your needs - in fact, you can remove any field from there, but make sure you remove reference from the code-behind. Then it's up to you how you style it. As an inspiration you can take a look at following site where I amended the layout as described above: svatba.vasilovi.cz/vzkazy.

Moreover, you can add your custom functionality in there using our API. You might find useful our API reference.

Best regards
Ondrej Vasil

User avatar
Member
Member
Willy - 6/8/2011 8:57:01 PM
   
RE:Blog Post Comment Form
Hello,

I can find a webpart to display the comment form?

User avatar
Kentico Support
Kentico Support
kentico_radekm - 6/8/2011 10:15:57 PM
   
RE:Blog Post Comment Form
Hello.

As my co-worker mentioned, this web part is placed \CMSWebParts\Blogs\BlogCommentView.ascx file. It internally uses ~/CMSModules/Blogs/Controls/BlogCommentView.ascx, so you can focuse on these 2 files (mainly the second one) in order to make some changes or a customization.
What exactly do you mean by „I can find a web part to display the comment form?, “ please? Yes, you can find it in file (location) above. Or do you have a problem finding that file, in the sense it is missing within your project folder?
Thank you in advance for clarification.

Best Regards,
Radek Macalik

User avatar
Member
Member
Willy - 6/14/2011 3:31:34 AM
   
RE:Blog Post Comment Form
Sorry for confusion. question was i'm not able to find the webpart... but I found it now and it's working.

Thanks a lot!

User avatar
Member
Member
lancetek - 6/9/2011 9:30:11 AM
   
RE:Blog Post Comment Form
You may want to take a look at how to develop custom web parts too!

Cheers,
Lance