Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Forum description in forum_topics.asp
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum description in forum_topics.asp

 Post Reply Post Reply
Author
suedechaser View Drop Down
Groupie
Groupie


Joined: 25 February 2006
Location: USA
Status: Offline
Points: 129
Post Options Post Options   Thanks (0) Thanks(0)   Quote suedechaser Quote  Post ReplyReply Direct Link To This Post Topic: Forum description in forum_topics.asp
    Posted: 06 November 2006 at 11:15am

Hi all,

Is it possible to view the forum description on the forum_topics.asp under the forum name as well as on default.asp?

thanks in advance

regards

suede
Back to Top
Hades View Drop Down
Newbie
Newbie


Joined: 17 January 2005
Status: Offline
Points: 23
Post Options Post Options   Thanks (0) Thanks(0)   Quote Hades Quote  Post ReplyReply Direct Link To This Post Posted: 07 November 2006 at 7:38am

The description is stored in the DB. Check on default.asp where it is and copy it into forum_topics.asp. It's a simple text line.

Back to Top
suedechaser View Drop Down
Groupie
Groupie


Joined: 25 February 2006
Location: USA
Status: Offline
Points: 129
Post Options Post Options   Thanks (0) Thanks(0)   Quote suedechaser Quote  Post ReplyReply Direct Link To This Post Posted: 07 November 2006 at 1:59pm
I found the following:

Response.Write("<br />" & strForumDiscription)

but alas, did not work.

Could you give a hint as to which line you are referring to please Hades?

regards

suede
Back to Top
suedechaser View Drop Down
Groupie
Groupie


Joined: 25 February 2006
Location: USA
Status: Offline
Points: 129
Post Options Post Options   Thanks (0) Thanks(0)   Quote suedechaser Quote  Post ReplyReply Direct Link To This Post Posted: 10 November 2006 at 5:50am
Hi,

Can anyone else pass on a little hint please?

regards

suede
Back to Top
jsaren View Drop Down
Groupie
Groupie
Avatar

Joined: 15 April 2006
Location: China
Status: Offline
Points: 95
Post Options Post Options   Thanks (0) Thanks(0)   Quote jsaren Quote  Post ReplyReply Direct Link To This Post Posted: 10 November 2006 at 7:52am

This is my forum code what how to show Forum description

=============================
Dim strForumDescription      'Holds the forum description
=============================
'Read the various forums from the database
'Initalise the strSQL variable with an SQL statement to query the database
strSQL = "" & _
"SELECT " & strDbTable & "Forum.Forum_ID, " & strDbTable & "Forum.Forum_name, " & strDbTable & "Forum.Forum_description, " & strDbTable & "Forum.No_of_topics, " & strDbTable & "Forum.No_of_posts, " & strDbTable & "Author.Username, " & strDbTable & "Forum.Last_post_author_ID, " & strDbTable & "Forum.Last_post_date, " & strDbTable & "Forum.Password, " & strDbTable & "Forum.Locked, " & strDbTable & "Forum.Hide, " & strDbTable & "Permissions.View_Forum " & _
"FROM " & strDbTable & "Forum" & strDBNoLock & ", " & strDbTable & "Permissions" & strDBNoLock & ", " & strDbTable & "Author" & strDBNoLock & " " & _
"WHERE " & strDbTable & "Forum.Forum_ID = " & strDbTable & "Permissions.Forum_ID " & _
 "AND " & strDbTable & "Forum.Last_post_author_ID = " & strDbTable & "Author.Author_ID " & _
 "AND " & strDbTable & "Forum.Sub_ID = " & intForumID & " " & _
 "AND (" & strDbTable & "Permissions.Author_ID = " & lngLoggedInUserID & " OR " & strDbTable & "Permissions.Group_ID=" & intGroupID & ") " & _
"ORDER BY " & strDbTable & "Forum.Forum_Order, " & strDbTable & "Permissions.Forum_ID;"
'Set error trapping
On Error Resume Next
=================================
<table class="basicTable" cellspacing="0" cellpadding="3" align="center">
 <tr>
  <td align="left" class="heading"  rowspan="2"><%
'Display the forum name and description
Response.Write(strForumName)
'If the forum is locked show a locked pad lock icon
If blnForumLocked = True Then Response.Write ("  <span class=""smText"">(<img src=""" & strImagePath & "forum_locked_icon.gif"" align=""baseline"" alt=""" & strTxtForumLocked & """> " & strTxtForumLocked & ")</span>")
%></td>
<td class="text" align="right">
<%
Response.Write(""& strForumDescription &"")
%></td>
 


Edited by jsaren - 10 November 2006 at 7:54am
Back to Top
suedechaser View Drop Down
Groupie
Groupie


Joined: 25 February 2006
Location: USA
Status: Offline
Points: 129
Post Options Post Options   Thanks (0) Thanks(0)   Quote suedechaser Quote  Post ReplyReply Direct Link To This Post Posted: 10 November 2006 at 10:14pm
Hi jsaren,

Thank you. I couldn't get it to work until I added the following line:

'Read in forum details from the database
     intCatID = CInt(rsCommon("Cat_ID"))
     strCatName = rsCommon("Cat_name")
     strForumName = rsCommon("Forum_name")
     strMasterForumName = rsCommon("Main_forum")
     intMasterForumID = CLng(rsCommon("Sub_ID"))
     blnForumLocked = CBool(rsCommon("Locked"))
     intShowTopicsWithin = CInt(rsCommon("Show_topics"))
     strForumDescription = rsCommon("Forum_Description")

regards

suede
Back to Top
jsaren View Drop Down
Groupie
Groupie
Avatar

Joined: 15 April 2006
Location: China
Status: Offline
Points: 95
Post Options Post Options   Thanks (0) Thanks(0)   Quote jsaren Quote  Post ReplyReply Direct Link To This Post Posted: 11 November 2006 at 2:56am
hehe,u r right!
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.