How to Customize the Blog

Posted by Community Admin on 04-Aug-2018 15:33

How to Customize the Blog

All Replies

Posted by Community Admin on 17-Jun-2011 00:00

Dear Team,

Really appreciate your fast processing on questions.

I have a Question regarding blogs to comment on the blog. There are Your name,Email,Website and Comment fields to enter the comment. What I need I just want only comment field to enter the comment or I could customize the comment section and use the email, name and website url for which the user login with. I made an another login screen to login the user on the website.

Please provide me necessary details or any demo code so that I could do that.

 

Thanks

Rohit

Posted by Community Admin on 17-Jun-2011 00:00

Hi Rohit,

You need to replace the CommentsDetailsView. Please check this forum thread.

In your custom class that inherits from CommentsDetailsView you should override OnPreRender where you can access the controls from the template and set predefined values.
Here is a list with all public properties.

Best wishes,
Ivan Dimitrov
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 22-Jun-2011 00:00

Dear Team,

I do not know from where i have to start, Please send me some steps to follow to do this.
i am very new to sitefinity and do not know how to do it. So please send me steps to follow.
 
Thanks Rohit

Posted by Community Admin on 22-Jun-2011 00:00

Hello Rohit,

Can you be more specific what exactly is not clear in the steps outlined in this post?

All the best,
Ivan Dimitrov
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 22-Jun-2011 00:00

Dear Team,

I have created a usercontrol extensioncomment.ascx
 

<%

 

@ Control Language="C#" AutoEventWireup="true" CodeBehind="extensioncomment.ascx.cs" Inherits="SitefinityWebApp.UserControls.extensioncomment" %>

 


Now what i have to do to customize the comment on blogs. I need to add a new class or paste the same code into the usercontrol by inheriting the CommentsDetailsView and where to register it. Can you specify what exactly need to do for achieving this.
i am using the trial version of sitefinity.
Rohit 

Posted by Community Admin on 22-Jun-2011 00:00

Hello Rohit,

Here are the steps you should follow

1. Create a class library
2. Create a custom class that inherits from Telerik.Sitefinity.Modules.GenericContent.Web.UI.Views.CommentsDetailsView
3. Override LayoutTemplateName and set your custom template -ascx
4. The template should be build as a an embedded resource  in the class library
5. Use virtual path provider settings to register the template
6. Replace the default view with your custom as my screenshot shows.

Kind regards,
Ivan Dimitrov
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 22-Jun-2011 00:00

Thanks Ivan for the steps

Could You please elaborate these point, I am bit confusing.

4. The template should be build as a an embedded resource  in the class library
5. Use virtual path provider settings to register the template
6. Replace the default view with your custom as my screenshot shows

Rohit

This thread is closed