Print Page | Close Window

Forum Statistics

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=1521
Printed Date: 01 April 2026 at 7:26am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Forum Statistics
Posted By: MKrivanek
Subject: Forum Statistics
Date Posted: 31 March 2003 at 8:55pm
Is there a way to turn off the forum statistics on the main page? I looked in the admin and didn't see it... could I be looking over something?  (preferably i wouldn't want to delete code to make this happen)



Replies:
Posted By: eaglesexec
Date Posted: 31 March 2003 at 10:19pm
ya i think you would have to delete code at this point. at least u can disable active members...

-------------
A good plan, violently executed now, is better than a perfect plan next week. -General George S. Patton.


Posted By: MKrivanek
Date Posted: 31 March 2003 at 11:24pm

hmm... alrighty then... will do. thanks



Posted By: hans3702
Date Posted: 31 March 2003 at 11:32pm

Write down the code you delete, and put that info here, so others can do the same easy.

JHH



-------------


Posted By: MKrivanek
Date Posted: 01 April 2003 at 12:38am

Delete the following code to remove forum statistics and active users from the main page (default.asp).  [Lines 525-631 deleted]:

<br/>
   <table width="<% = strTableVariableWidth %>" border="0" cellspacing="0" cellpadding="1" bgcolor="<% = strTableBorderColour %>" align="center">
 <tr>
  <td>
  <table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="<% = strTableBgColour %>">
    <tr>
     <td bgcolor="<% = strTableBgColour %>">
   <table width="100%" border="0" cellspacing="0" cellpadding="0" bgcolor="<% = strTableBgColour %>">
    <tr>
    <td>
         <table width="100%" border="0" cellspacing="1" cellpadding="4">
          <tr>
           <td bgcolor="<% = strTableTitleColour %>" width="44%" class="tHeading" background="<% = strTableTitleBgImage %>"><% = strTxtForumStatistics %></td>
          </tr>
          <tr>
           <td bgcolor="<% = strTableColour %>" background="<% = strTableBgImage %>" class="smText" valign="top"><%
          
          
Response.Write(vbCrLf & "  " & strTxtOurUserHavePosted & "&nbsp;" & lngTotalNumberOfPosts & "&nbsp;" & strTxtPostsIn & "&nbsp;" & lngTotalNumberOfTopics & "&nbsp;" & strTxtTopicsIn & "&nbsp;" & intNumberofForums & "&nbsp;" & strTxtForums)
Response.Write(vbCrLf & "  <br />" & strTxtLastPostOn & "&nbsp;" & DateFormat(dtmLastEntryDateAllForums, saryDateTimeData) & "&nbsp;" & strTxtAt & "&nbsp;" & TimeFormat(dtmLastEntryDateAllForums, saryDateTimeData) & " " & strTxtBy & "&nbsp;<a href=""JavaScript:openWin('pop_up_profile.asp?PF=" & lngLastEntryUserIDAllForums & "','profile','toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=590,height=425')"" class=""smLink"">" & strLastEntryUserAllForums & "</a>")

'Get the latest forum posts

'Cursor type to one to count
rsCommon.CursorType = 1

'Get the last signed up user
'Initalise the strSQL variable with an SQL statement to query the database
If strDatabaseType = "SQLServer" Then
 strSQL = "EXECUTE " & strDbProc & "AuthorDesc"
Else
 strSQL = "SELECT " & strDbTable & "Author.Username, " & strDbTable & "Author.Author_ID "
 strSQL = strSQL & "FROM " & strDbTable & "Author "
 strSQL = strSQL & "ORDER BY " & strDbTable & "Author.Author_ID DESC;"
End If

'Query the database
rsCommon.Open strSQL, adoCon

'Display some statistics for the members
If NOT rsCommon.EOF Then

Response.Write(vbCrLf & "  <br />" & strTxtWeHave & "&nbsp;" & rsCommon.RecordCount & "&nbsp;" & strTxtForumMembers)
Response.Write(vbCrLf & "  <br />" & strTxtTheNewestForumMember & "&nbsp;<a href=""JavaScript:openWin('pop_up_profile.asp?PF=" & rsCommon("Author_ID") & "','profile','toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=590,height=425')"" class=""smLink"">" & rsCommon("Username") & "</a>")


End If

'Close the recordset
rsCommon.Close


'Get the number of active users if enabled
If blnActiveUsers Then
 'Initialise the SQL variable with an SQL statement count the number of records
 If strDatabaseType = "SQLServer" Then
  strSQL = "EXECUTE " & strDbProc & "CountOfActiveUsers"
 Else
  strSQL = "SELECT Count(" & strDbTable & "ActiveUser.Author_ID) AS ActiveUser From " & strDbTable & "ActiveUser;"
 End If

 'Query the database
 rsCommon.Open strSQL, adoCon

 'Read in the active users from the recordset
 intActiveUsers = CInt(rsCommon("ActiveUser"))

 'Close the recordset
 rsCommon.Close


 'Get the number of active guests
 'Initialise the SQL variable with an SQL statement count the number of records
 If strDatabaseType = "SQLServer" Then
  strSQL = "EXECUTE " & strDbProc & "CountOfActiveGuests"
 Else
  strSQL = "SELECT Count(" & strDbTable & "ActiveUser.Author_ID) AS ActiveUser From " & strDbTable & "ActiveUser WHERE " & strDbTable & "ActiveUser.Author_ID=2;"
 End If

 'Query the database
 rsCommon.Open strSQL, adoCon

 'Read in the active guests from the recordset
 intActiveGuests = CInt(rsCommon("ActiveUser"))

 'To save another database hit we can get the number of members online by taking the number of guest away from the total active users
 intActiveMembers = intActiveUsers - intActiveGuests

 'Close the recordset
 rsCommon.Close


 Response.Write(vbCrLf & "  <br />" & strTxtInTotalThereAre & "&nbsp;" & intActiveUsers & "&nbsp;<a href=""active_users.asp"" target=""_self"" class=""smLink"">" & strTxtActiveUsers & "</a> " & strTxtOnLine & ",&nbsp;" & intActiveGuests & "&nbsp;" & strTxtGuestsAnd & "&nbsp;" & intActiveMembers & "&nbsp;" & strTxtMembers)
End If
           %>
           </td>
          </tr>
         </table>
        </td>
       </tr>
      </table>
     </td>
    </tr>
   </table>
   </td>
 </tr>
</table>



Posted By: whittibo
Date Posted: 28 May 2003 at 8:40pm

HELLO AGAIN!!

I am still just poking around trying to see what all I can/can't do with my new toy!

I am wondering if I can only delete the part of the stitistics that lists how many posts in how many forums?  BECAUSE.. not everyone has access to all the forum, and if they are told there are 9 forums, but they only see 7.. well.. that's not very kind..

Thanks so much for all your guys help here.  I love my new forum.. it's exactly what I was searching for!



Posted By: xeerex
Date Posted: 28 May 2003 at 9:06pm

Sure...you can remove it from the response.write in the code listed above.

FYI, I wouldn't always post code in the forum. Its better to upload a zipped mod somewhere since a lot of coding in the forum could really slow searches down eventually.



-------------
http://webspacegeeks.com - Need Hosting, Domains, Dedicated Servers?
http://www.smartergeek.com - web design | pc support | training | podcasts | video production



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net