2) reply.aspx : The topic viewing and replying page
<%@ Page Language="C#" EnableSessionState="False" Debug="True" %>
<%@ Import Namespace="System" %>
<%@ Assembly Name="System.Data" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.ADO" %>
Post New Topic. <%-- These are the imported assemblies and namespaces needed --%>
<%-- Include a header file 'header.inc' --%>
| Author Name |
Message |
|---|
<%-- Below I am encapsulating the email of the author over the name of the author
so that when you click on the author a e-mail gets sent to him
Also I am geting the DateTime from the DataBase and Displaying the Date and Time separately --%>
<%= ""+dr["name"]+"" %>
<%= dr["date"].ToString().ToDateTime().ToShortDateString() %>
<%= dr["date"].ToString().ToDateTime().ToShortTimeString() %>
|
Subject: <%=dr["subject"] %> |
<%=dr["message"] %> |
<%-- Get all the replies to the Original post and show them --%>
<% int no = rs.Tables["reply"].Rows.Count ;
if(no>0)
{
for(int j=0 ;j
{
DataRow rd = rs.Tables["reply"].Rows[j] ;
%>
<%=""+rd["name"]+"" %>
<%= rd["date"].ToString().ToDateTime().ToShortDateString() %>
<%= rd["date"].ToString().ToDateTime().ToShortTimeString() %>
|
<%=rd["message"] %> |
<%
}
}
%>
Click Here to go to back to Forum.
Reply to the Above Post.