hello guys. Just need a little bit of help with the birthday mod.
1.) I can't fine the <table>
for the width. Am I missing something? I can't find it. All I need the the width to fit the screen.
2.) Expand/collapse to disappear (go away for good). I don't want this in the code. I want one for everything (user's logged in, not logged in, etc.)
This is the code for inc_birthday.asp:
<%
'#################################################################################
'## Snitz Forums 2000 v3.4.04
'#################################################################################
'## Copyright (C) 2000-04 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free software; you can redistribute it and/or
'## modify it under the terms of the GNU General Public License
'## as published by the Free Software Foundation; either version 2
'## of the License, or (at your option) any later version.
'##
'## All copyright notices regarding Snitz Forums 2000
'## must remain intact in the scripts and in the outputted HTML
'## The "powered by" text/logo with a link back to
'## http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful,
'## but WITHOUT ANY WARRANTY; without even the implied warranty of
'## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
'## GNU General Public License for more details.
'##
'## You should have received a copy of the GNU General Public License
'## along with this program; if not, write to the Free Software
'## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
'##
'## Support can be obtained from our support forums at:
'## http://forum.snitz.com
'##
'## Correspondence and Marketing Questions can be sent to:
'## manderson@snitz.com
'##
'#################################################################################
'## MOD: Birthdays v1.0 for Snitz Forums v3.4
'## Author: Michael Reisinger (OneWayMule)
'## File: inc_birthdays.asp
'##
'## Get the latest version of this MOD at
'## http://www.onewaymule.org/onewayscripts/
'#################################################################################
Sub DisplayBirthdays(intRange,intAge)
Call DoHideCategory("Birthdays")
HideForumCat = strUniqueID & "HideCatBirthdays"
If Request.Cookies <> "Y" Then
strBDToday = Left(DateToStr(strForumTimeAdjust),8) & "000000"
strBDRecentDay = Mid(DateToStr(DateAdd("d",-intRange,strToDate(strBDToday))),5,4)
strBDUpcomingDay = Mid(DateToStr(DateAdd("d",+intRange,strToDate(strBDToday))),5,4)
strBDToday = Mid(strBDToday,5,4)
strsql = "SELECT MEMBER_ID, M_NAME, M_DOB FROM " & strMemberTablePrefix & "MEMBERS WHERE M_DOB<>'' AND M_STATUS=1 ORDER BY Right(M_DOB,4)"
Set rsBirthday = my_conn.Execute(strsql)
bolRecentBD = False
bolTodaysBD = False
bolUpcomingBD = False
If intRange = 1 Then
strRecentBD = "Yesterday: "
strUpcomingBD = "Tomorrow: "
Else
strRecentBD = "Recent: "
strUpcomingBD = "Upcoming: "
End If
strTodaysBD = ""
If NOT rsBirthday.EOF Then
arrBD = rsBirthday.GetRows()
bolBDFound = True
Else
bolBDFound = False
End If
rsBirthday.Close
Set rsBirthday = Nothing
If bolBDFound Then
For iBD = 0 to ubound(arrBD, 2)
intBDID = arrBD(0, iBD)
strBDName = chkString(arrBD(1, iBD),"display")
intTPPostcount = arrBD(2, iBD)
strDOB = Right(arrBD(2, iBD),4)
strBirthdate = strToDate(arrBD(2, iBD) & "000000")
If strDOB = strBDToday Then
If bolTodaysBD = True Then
strTodaysBD = strTodaysBD & ", "
End If
strTodaysBD = strTodaysBD & profileLink(strBDName,intBDID) & " ("
If intAge = 1 Then
strTodaysBD = strTodaysBD & DisplayUsersAge(strBirthdate) & " on "
End If
strTodaysBD = strTodaysBD & monthName(Datepart("m",strBirthDate)) & " " & day(strBirthDate) & ")"
bolTodaysBD = True
End If
If strBDRecentDay > strBDToday Then
If (strDOB > strBDRecentDay AND strDOB < "1231") OR (strDOB > "0101" AND strDOB < strBDToday) Then
If bolRecentBD = True Then
strRecentBD = strRecentBD & ", "
End If
strRecentBD = strRecentBD & profileLink(strBDName,intBDID) & " ("
If intAge = 1 Then
strRecentBD = strRecentBD & DisplayUsersAge(strBirthdate) & " on "
End If
strRecentBD = strRecentBD & monthName(Datepart("m",strBirthDate)) & " " & day(strBirthDate) & ")"
bolRecentBD = True
End If
Else
If strDOB < strBDToday AND strDOB >= strBDRecentDay Then
If bolRecentBD = True Then
strRecentBD = strRecentBD & ", "
End If
strRecentBD = strRecentBD & profileLink(strBDName,intBDID) & " ("
If intAge = 1 Then
strRecentBD = strRecentBD & DisplayUsersAge(strBirthdate) & " on "
End If
strRecentBD = strRecentBD & monthName(Datepart("m",strBirthDate)) & " " & day(strBirthDate) & ")"
bolRecentBD = True
End If
End If
If strBDUpcomingDay < strBDToday Then
If (strDOB =< strBDUpcomingDay AND strDOB >= "0101") OR (strDOB =< "1231" AND strDOB > strBDToday) Then
If bolUpcomingBD = True Then
strUpcomingBD = strUpcomingBD & ", "
End If
strUpcomingBD = strUpcomingBD & profileLink(strBDName,intBDID) & " ("
If intAge = 1 Then
strUpcomingBD = strUpcomingBD & DisplayUsersAge(strBirthdate)+1 & " on "
End If
strUpcomingBD = strUpcomingBD & monthName(Datepart("m",strBirthDate), true) & " " & day(strBirthDate) & ")"
bolUpcomingBD = True
End If
Else
If strDOB > strBDToday AND strDOB <= strBDUpcomingDay Then
If bolUpcomingBD = True Then
strUpcomingBD = strUpcomingBD & ", "
End If
strUpcomingBD = strUpcomingBD & profileLink(strBDName,intBDID) & " ("
If intAge = 1 Then
strUpcomingBD = strUpcomingBD & DisplayUsersAge(strBirthdate)+1 & " on "
End If
strUpcomingBD = strUpcomingBD & monthName(Datepart("m",strBirthDate), true) & " " & day(strBirthDate) & ")"
bolUpcomingBD = True
End If
End If
Next
End If
intBDRowSpan = 1
If bolRecentBD Then
intBDRowSpan = intBDRowSpan + 1
strRecentBD = strRecentBD & "."
End If
If bolTodaysBD Then
strTodaysBD = strTodaysBD & "."
Else
strTodaysBD = "None."
End If
If bolUpcomingBD Then
intBDRowSpan = intBDRowSpan + 1
strUpcomingBD = strUpcomingBD & "."
End If
End If
If Request.Cookies(HideForumCat) = "Y" Then
Response.Write " <td bgcolor=""" & strCategoryCellColor & """ colspan=""" & sGetColspan(7,6) & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""" & ScriptName & "?" & HideForumCat & "=N"">" & getCurrentIcon(strIconPlus,"Expand This Category","") & "</a> <b>Birthdays</b></font></td>" & vbNewLine
Else
Response.Write " <td bgcolor=""" & strCategoryCellColor & """ colspan=""" & sGetColspan(7,6) & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""" & ScriptName & "?" & HideForumCat & "=Y"">" & getCurrentIcon(strIconMinus,"Collapse This Category","") & "</a> <b>Birthdays</b></font></td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
If Request.Cookies(HideForumCat) <> "Y" Then
Response.write " <tr>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strForumCellColor & """ colspan=""1"" rowspan=""" & intBDRowSpan & """ valign=""middle"">" & getCurrentIcon(strIconBirthdays,"","") & vbNewLine & _
" </td>" & vbNewLine
If (NOT bolTodaysBD) AND (NOT bolUpcomingBD) AND (NOT bolRecentBD) Then
Response.Write " <td bgcolor=""" & strForumCellColor & """ colspan=""" & sGetColspan(7,5) & """>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>None today." & vbNewLine
Else
Response.Write " <td bgcolor=""" & strForumCellColor & """ colspan=""" & sGetColspan(7,5) & """>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & strTodaysBD & "</font>" & vbNewLine & _
" </td></tr>" & vbNewLine
If bolUpcomingBD Then
Response.Write " <tr><td bgcolor=""" & strForumCellColor & """ colspan=""" & sGetColspan(7,5) & """>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>" & strUpcomingBD & "</font></td></tr>" & vbNewLine
End If
If bolRecentBD Then
Response.Write " <tr><td bgcolor=""" & strForumCellColor & """ colspan=""" & sGetColspan(7,5) & """>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>" & strRecentBD & "</font></td></tr>" & vbNewLine
End If
End If
Response.Write " </tr>" & vbNewLine
End If
End Sub
%>
Thanks,
shaggy073077