Click here to Skip to main content
15,897,273 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi I have comment system::

I have a page that show the latest comments(title of the comment) just appear ,and when the user click on it should redirect it to the related post(it's own post)
How i can link the title(column) to the post when the user click on it?
Posted
Comments
Karthik. A 13-Jun-12 16:52pm    
What is stopping you? Post some code - what you have and what you expect and also re-tag your question, based on if the project is in webforms / mvc.

a simple solution,
 
Share this answer
 
Hi
I assume that you are using a grid view or something like that....
Make the title column to TemplateColumn and inside Item Template do the following...

<itemtemplate>
]]>


i.e. Method names or tag name may be incorrect...
 
Share this answer
 
Comments
Lotus90 14-Jun-12 8:42am    
I'm working on GridView.
What u mean by inside Item template ? it's give an error
sorry. title =
C#
<a href="commentdetails.aspx?id="><![CDATA[<%=commentid%>]]>""></a>
 
Share this answer
 
Comments
Rahul Rajat Singh 14-Jun-12 8:05am    
please update your original solution and dont post another solution for this.
Thanks ,,but where i shall write this
]]>
since i'm working in gridview
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900