Allow Comments in News and Articles
To allow users to post comments in your news please download this custom module for News.NET application.
You can download this module by clicking the following url http://www.dotnetwebapps.com/Downloads/News.NET/CustomModules/Comments.v.0.1.rar
To install this module into News.NET application follow this steps.
1.Download and extract the .rar package.
In this package you will find two folders and one user control.
2.Create database tables and queries ,stored procedures. You will do this by executing .sql script against your News.NET database. Sql instalation script is in Database/SqlDataProvider/Scripts/0.1.0.0.sql. Use Sql Query Analyzer or your tool of choice.
3.Open the bin folder.The bin folder contains two files (News.Modules.Comments.dll,News.Modules.Comments.SqlDataProvider.dll).Copy this files into bin folder of News.NET application.
4.Now you can copy the comments folder and paste into News/Modules folder. Where News is the folder where your News.NET application is installed.
5.Also you need to edit your template files if you wish that your users have option to post comments.
Open your template file in text editor like Notepad. Add the following line of code
<%@ Register TagPrefix="aspx" TagName="Comments" src="~/Modules/Comments/Comments.ascx" %>
just afther this line
<%@ Control autoEventWireUp="false" Inherits="News.Template" CodeBehind="~/Admin/Template.ascx.vb" %>
Also add this code to your template file
<aspx:Comments id=comments runat="server"/>.
6.One more step to go.You must modify language files.Add this to your language files.
;### /// File Modules/Comments/Comments.ascx
txtcommentnameerror=Please enter your name
txtcommentadderror=Please enter comment
txtcommentname=Your Name
txtcommentadd=Enter Comment
btncommentadd=Add Comment
btncommentdelete=Delete selected comments
;### /// File Modules/Comments/Comments.ascx.vb
txtcommentmessagesavesuccess=Comment successfully added.Thank you
txtcommentmessagesaveerror=Error Occured.
Once you added this you will need to compile language files.Just double click on compile.bat file in your language folder.
If you have any suggestions please send me an e-mail nikola.ristic@vt.htnet.hr.If you need source code for this module send me an e-mail. |