Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 Portal Mod add-on (events calendar)
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 3

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 24 October 2003 :  16:40:08  Show Profile
Pre-requisites:
Portal Mod: http://forum.snitz.com/forum/topic.asp?TOPIC_ID=43485
Events Calendar Mod

Description:
Places the calendar and upcoming events on the right hand side of the Portal Mod page (portal.asp)

3 Additions (portal.asp):

under (around line 44):
<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp"-->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->

add:
<!--#INCLUDE FILE="cal_functions.asp"-->
<!--#INCLUDE FILE="cal_style.asp"-->

under (around line 118):
call DisplayCategories(0, strCMSRightNavWidth)

add:
call DisplayCalender(strCMSRightNavWidth)

above (around line 397):
sub StartTable(byval Width, byval Heading)

add:
sub DisplayCalender(byval Width)

	dateHolder = dateValue(strForumTimeAdjust)
	call DrawMonth(dateHolder,1,1,1)
	call TableSpacer(TABLE_SPACER_WIDTH, TABLE_SPACER_HEIGHT)
	call StartTable(Width, "Upcoming Events")
	call WriteUpcomingEvents()	
	call EndTable()				
	call TableSpacer(TABLE_SPACER_WIDTH, TABLE_SPACER_HEIGHT)

end sub

The UK MkIVs Forum

lsakizada
New Member

USA
90 Posts

Posted - 25 October 2003 :  14:34:45  Show Profile
Thank you David!
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 25 October 2003 :  16:20:53  Show Profile
I take it that it worked then

If anyone installs this, could they possibly provide a link for the benefit of others, I don't have a live base install set up

The UK MkIVs Forum
Go to Top of Page

schef
Junior Member

USA
164 Posts

Posted - 25 October 2003 :  18:40:35  Show Profile  Visit schef's Homepage  Send schef an AOL message
I had to chop the code up a little to fit the layout of my site, but you can see an example HERE. The Events listing is on the left hand side. The mod would have a calendar diagram as well, but I had to take it out to fit in my column.

THANKS for this mod!!!! I had been trying to do this for a while with little success. However my entire calendar mod is a little off, but this one works great. Thanks

On a separate note, any idea how I could get the listing to not indent?

Sorry, but there is one more question I have. The columns on the right of my site "Reviews, Articles.." are listed in ascending order. Is there an easy way to make that descending? Got it. WAHOO

ATV Outdoors

Edited by - schef on 25 October 2003 18:52:37
Go to Top of Page

Faizan
Average Member

United Kingdom
592 Posts

Posted - 25 October 2003 :  19:08:04  Show Profile  Visit Faizan's Homepage  Send Faizan an AOL message  Send Faizan an ICQ Message  Send Faizan a Yahoo! Message
This is nice. Thanks David!





»Snitz Graphics
Go to Top of Page

soxc
New Member

53 Posts

Posted - 25 October 2003 :  19:13:33  Show Profile
I think that you need to add the sub TableSpacer.

I also wanted to say a big thanks for your work on the mods etc..
I have been finally working on modding my forum and your work has been a big help (so thanks!).
Go to Top of Page

pokemon
Junior Member

151 Posts

Posted - 25 October 2003 :  23:33:26  Show Profile
Hi David,
After adding your mod, i'm having an error like this:

Microsoft VBScript compilation error '800a0411'

Name redefined

/phorum/inc_adovbs.asp, line 14

Const adOpenForwardOnly = 0
------^

Where do i should remove it. Thanks
Go to Top of Page

The Impact
Junior Member

Australia
398 Posts

Posted - 25 October 2003 :  23:47:15  Show Profile
Looks like the inc_adovbs.asp file has been included twice.
Go to Top of Page

soxc
New Member

53 Posts

Posted - 25 October 2003 :  23:55:43  Show Profile
I know that config.asp has the include called at the top of the page and should not be removed so it must be another page (like Impact mentioned).

Do you only get the error with Portal.asp?

Go to Top of Page

pokemon
Junior Member

151 Posts

Posted - 26 October 2003 :  00:02:22  Show Profile
Thanks,

i after i changed the <!--#INCLUDE FILE="cal_style.asp"--> to
<LINK rel="stylesheet" href="cal_style.asp" type="text/css">
and i'm having this error:

Microsoft JET Database Engine error '80040e14'
Syntax error (missing operator) in query expression 'T.FORUM_ID IN () AND E.EVENT_DATE BETWEEN '20031001000000' AND '20031031000000''.

/phorum/cal_functions.asp, line 78

i don't know what to do know. Please help me

Edited by - pokemon on 26 October 2003 00:03:45
Go to Top of Page

pokemon
Junior Member

151 Posts

Posted - 26 October 2003 :  00:11:27  Show Profile
Yes all these pages is in my portal.asp and this is my portal code look like. Red is my recently add in

<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp"-->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="content.asp" -->
<!--#INCLUDE FILE="inc_contentdisplay.asp" -->
<!--#INCLUDE FILE="cal_functions.asp"-->
<LINK rel="stylesheet" href="cal_style.asp" type="text/css">



<%
dim sThisPage
const TABLE_SPACER_WIDTH = 4
const TABLE_SPACER_HEIGHT = 4
sThisPage = Request.ServerVariables("SCRIPT_NAME")

call Main()

sub Main()

	dim lContentID, lCategoryID, sMode, sSearchTerm

	lContentID		=	CInt(Request.QueryString("ContentID"))
	lCategoryID		=	CInt(Request.QueryString("CategoryID"))
	sMode			=	Request.QueryString("Mode")
	sSearchTerm		=	Trim(Request.Form("txtSearch"))
	
	if strCMSTitleDisplay = "1" then
	
		Response.Write	"      <table border=""0"" width=""100%"" align=""center"">" & vbNewLine & _
				"        <tr>" & vbNewLine & _
				"          <td width=""33%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
				"          " & getCurrentIcon(strIconFolderOpen,"All Forums","") & " <a href=""default.asp"">All Forums</a><br />" & vbNewLine & _
				"          " & getCurrentIcon(strIconBar,"","") & getCurrentIcon(strIconFolderOpenTopic,strCMSPageTitle,"") & " "& strCMSPageTitle &"<br /></font></td>" & vbNewLine & _
				"        </tr>" & vbNewLine & _
				"      </table>" & vbNewLine
	
	end if
	
	Response.Write  "		<table border=""0"" width=""100%"" cellspacing=""0"" cellpadding=""0"">" &vbCrLf &_
			"		<tr>" &vbCrLf 
	'###########################################################################################
	'###########################################################################################
	'LEFT NAVIGATION
	if strCMSLeftNavDisplay = "1" then
		Response.Write	"			<td width="""& strCMSLeftNavWidth &""" valign=""top"">" &vbCrLf
		'call DisplayCategories(1, strCMSLeftNavWidth)
		%>
		<!--#INCLUDE FILE="inc_login.asp" -->
		
		<%
		
		Response.Write	"			</td>" & vbNewLine &_		
				"			<td style=""width: "& TABLE_SPACER_WIDTH &"px""><img src="""& strImageUrl &"clear.gif"" width="""& TABLE_SPACER_WIDTH &""" height=""1""></td>" & vbNewLine
	end if
	
	'###########################################################################################
	'###########################################################################################
	'###########################################################################################
	'CENTRE CONTENT
	Response.Write	"			<td width=""100%"" valign=""top"">"
	if lContentID > 0 and lCategoryID > 0 then
	
		call DisplayContentItem(lContentID, lCategoryID)
		

	elseif lCategoryID > 0 then
		call ListCategoryItems(lCategoryID)
	elseif lContentID > 0 then
		call DisplayContentItem(lContentID, "")
	elseif Request.Form("Method_Type") = "Search" then 
		call SearchResults(sSearchTerm)
	else 'must be home page so show default text
		if IsNumeric(strCMSDefaultCID) then
			call DisplayContentItem(strCMSDefaultCID, "")
			%><!--#INCLUDE FILE="includes/virus_scan.asp" --><%
			call DisplayContent (0, 0, 2, 3, 0, 10, 200, 0, 0, 1, 1, 0, "10 B#224;i M#7899;i", 420, "topic.asp")
			

				else
			call NoContent()
		end if
	end if
	
	Response.Write  "			</td>"
	'###########################################################################################
	'###########################################################################################
	'###########################################################################################
	'RIGHT NAVIGATION
	if strCMSRightNavDisplay = "1" then
		Response.Write	"			<td style=""width: "& TABLE_SPACER_WIDTH &"px""><img src="""& strImageUrl &"clear.gif"" width="""& TABLE_SPACER_WIDTH &""" height=""1""></td>" & vbNewLine &_
				"			<td width="""& strCMSRightNavWidth &""" valign=""top"">" &vbCrLf
		if strCMSLMInstalled = "1" then call DisplayLinks(strCMSRightNavWidth)
		if strCMSEnableSearch = "1" then 
			call DisplaySearch(strCMSRightNavWidth)
			call DisplayForumSearch(strCMSRightNavWidth)
		end if
		call DisplayCategories(0, strCMSRightNavWidth)
		
		%>
		<!--#INCLUDE FILE="includes/member_spotlight.asp" -->
		<!--#INCLUDE FILE="includes/inc_top_posters.asp" -->
		
		
		<%
	    
		call DisplayCalender(strCMSRightNavWidth)
		
			Response.Write	"			</td>"
			
	end if
	'###########################################################################################

	Response.Write  "		</tr>" &vbCrLf &_
			"		</table>" 
	call WriteFooter()

end sub



sub DisplayCategories(byval IsLeft, byval Width)

	dim rsCatList, rsContList
	dim lItemsToDisplay, lCategoryID
	
	if IsLeft then lItemsToDisplay = strCMSLeftNavItems else lItemsToDisplay = strCMSRightNavItems
	
	'Get categories which have approved content
	strSql = "SELECT DISTINCT "
	strSql = strSql & strTablePrefix & "CMS_CATEGORY.CAT_ID, " 
	strSql = strSql & strTablePrefix & "CMS_CATEGORY.CAT_TITLE, "
	strSql = strSql & strTablePrefix & "CMS_CATEGORY.CAT_ORDER "
	strSql = strSql & "FROM " & strTablePrefix & "CMS_CATEGORY, " & strTablePrefix & "CMS_CONTENT "
	strSql = strSql & "WHERE " & strTablePrefix & "CMS_CATEGORY.CAT_ISLEFT = " & IsLeft & " "
	strSql = strSql & "AND " & strTablePrefix & "CMS_CONTENT.CONT_STATUS = 1 "
	strSql = strSql & "AND " & strTablePrefix & "CMS_CATEGORY.CAT_ID = " & strTablePrefix & "CMS_CONTENT.CAT_ID "
	strSql = strSql & "ORDER BY " & strTablePrefix & "CMS_CATEGORY.CAT_ORDER ASC"
	
	set rsCatList = my_Conn.Execute(strSql)
	
	do while NOT rsCatList.EOF
	
		lCategoryID = rsCatList.Fields("CAT_ID").Value

		call StartTable(Width, rsCatList.Fields("CAT_TITLE").Value)
		
		strSql = "SELECT " 
		strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_ID, " 
		strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_TITLE "
		strSql = strSql & "FROM " & strTablePrefix & "CMS_CONTENT "
		strSql = strSql & "WHERE " & strTablePrefix & "CMS_CONTENT.CAT_ID = " & lCategoryID & " "
		strSql = strSql & "ORDER BY " & strTablePrefix & "CMS_CONTENT.CONT_LAST_EDIT ASC"
		
		set rsContList = Server.CreateObject("ADODB.Recordset")
		rsContList.CursorLocation = adUseClient
		rsContList.Open strSql, my_Conn	
				
		do while NOT rsContList.EOF and rsContList.AbsolutePosition <= CInt(lItemsToDisplay)
			
			Response.Write "<a href="""& Request.ServerVariables("SCRIPTNAME") &"?ContentID="& rsContList.Fields("CONT_ID").Value &"&CategoryID="& lCategoryID &""">"& rsContList.Fields("CONT_TITLE").value &"</a><br />"		
			rsContList.MoveNext
		loop
				
		if rsContList.RecordCount > CInt(lItemsToDisplay) then
			Response.Write "<a href="""& sThisPage &"?CategoryID="& lCategoryID &""">more "& rsCatList.Fields("CAT_TITLE").value &"....</a>"		
		end if
		
		set rsContList = nothing	
		
		call EndTable()
				
		rsCatList.MoveNext
	loop
	set rsCatList = nothing

end sub


sub DisplayContentItem(byval ContentID, byval ContentCategoryID)

	dim strSql, rsContent	
	
	strSql = "SELECT " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_ID, " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_TITLE, " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_BODY, "
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_DATE, " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_AUTHOR, " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_LAST_EDIT "
	strSql = strSql & "FROM " & strTablePrefix & "CMS_CONTENT "
	strSql = strSql & "WHERE " & strTablePrefix & "CMS_CONTENT.CONT_ID = " & ContentID
		
	set rsContent = my_Conn.Execute(strSql)
	
	call StartTable("100%", rsContent.Fields("CONT_TITLE").Value)
	
	Response.Write formatStr(rsContent.Fields("CONT_BODY").Value) &"<br /><br />"& vbCrLf &_
			"Author: <a href=""pop_profile.asp?mode=display&id="& rsContent.Fields("CONT_AUTHOR").Value & """>"& getMemberName(rsContent.Fields("CONT_AUTHOR").Value) & "</a><br />" &_
			"Posted: "& ChkDate(rsContent.Fields("CONT_DATE").Value, "</b>" ,true) &vbCrLf
			
	If StrComp(rsContent.Fields("CONT_DATE").Value, rsContent.Fields("CONT_LAST_EDIT").Value, vbTextCompare) <> 0 then
		Response.Write  "<br />Edited: "& ChkDate(rsContent.Fields("CONT_LAST_EDIT").Value, "</b>" ,true) &vbCrLf
	end if
	
	set rsContent = nothing
	
	call EndTable()
			
end sub


sub ListCategoryItems(byval CategoryID)

	dim rsContList, rsCat
	dim sCategoryTitle

	strSql = "SELECT " 
	strSql = strSql & strTablePrefix & "CMS_CATEGORY.CAT_TITLE "
	strSql = strSql & "FROM " & strTablePrefix & "CMS_CATEGORY "
	strSql = strSql & "WHERE " & strTablePrefix & "CMS_CATEGORY.CAT_ID = "& CategoryID
	
	set rsCat = my_Conn.Execute(strSql)
	sCategoryTitle = rsCat.Fields("CAT_TITLE").Value
	set rsCat = nothing
	
	call StartTable("100%", sCategoryTitle)
			
	strSql = "SELECT " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_ID, " 
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_TITLE, "
	strSql = strSql & strTablePrefix & "CMS_CONTENT.CONT_SUMMARY "
	strSql = strSql & "FROM " & strTablePrefix & "CMS_CONTENT "
	strSql = strSql & "WHERE " & strTablePrefix & "CMS_CONTENT.CAT_ID = " & CategoryID & " "
	strSql = strSql & "ORDER BY " & strTablePrefix & "CMS_CONTENT.CONT_LAST_EDIT ASC"
		
	set rsContList = my_Conn.Execute(strSql)
	
	do while NOT rsContList.EOF
		Response.Write   "				<a href="""& sThisPage &"?ContentID="& rsContList.Fields("CONT_ID").Value &"&CategoryID="& CategoryID &""">"& rsContList.Fields("CONT_TITLE").Value &"</a><br />" &vbCrLf &_
				"							"& rsContList.Fields("CONT_SUMMARY").Value &"<br />" &vbCrLf
		rsContList.MoveNext
		if NOT rsContList.EOF then Response.Write("<hr>")
	loop
	
	set rsContList = nothing

	call EndTable()
			
end sub


sub DisplaySearch(byval Width)

	call StartTable(Width, "Search")
	
	Response.Write "			<form method=""post"" action="""& sThisPage &""" onSubmit=""if (this.txtSearch.value != ''){return true}else{return false}"" id=form1 name=form1>" &vbCrLf &_
			"			<input type=""hidden"" name=""Method_Type"" value=""Search"">" &vbCrLf &_
			"			<input type=""text"" name=""txtSearch"" style=""width:100%"" maxlength=""50""><br>" &vbCrLf &_
			"			<input type=""submit"" name=""btnSubmit"" value=""Search"">" &vbCrLf &_		
			"			</form>" &vbCrLf
	
	call EndTable()				

end sub


sub DisplayForumSearch(byval Width)

	call StartTable(Width, "Forum Search")
	
	Response.Write "			<form method=""post"" action=""search.asp?mode=DoIt"">" &vbCrLf &_
			"			<option type=""hidden"" name=""SearchMessage"" value=""0"">" &vbCrLf &_
			"			<option type=""hidden"" name=""Forum"" value=""0"">" &vbCrLf &_
			"			<option type=""hidden"" name=""andor"" value=""1"">" &vbCrLf &_
			"			<option type=""hidden"" name=""SearchMember"" value=""0"">" &vbCrLf &_
			"			Search For<br><input type=""text"" name=""Search"" style=""width:100%"" maxlength=""40""><br>" &vbCrLf &_
			"	        By Date<br><select name=""SearchDate"" style=""width:100%"">" & vbNewLine & _
			"			<option value=""0"">Any Date</option>" & vbNewLine & _
			"			<option value=""1"">Since Yesterday</option>" & vbNewLine & _
			"			<option value=""2"">Since 2 Days Ago</option>" & vbNewLine & _
			"			<option value=""5"">Since 5 Days Ago</option>" & vbNewLine & _
			"			<option value=""7"">Since 7 Days Ago</option>" & vbNewLine & _
			"			<option value=""14"">Since 14 Days Ago</option>" & vbNewLine & _
			"			<option value=""30"">Since 30 Days Ago</option>" & vbNewLine & _
			"			<option value=""60"">Since 60 Days Ago</option>" & vbNewLine & _
			"			<option value=""120"">Since 120 Days Ago</option>" & vbNewLine & _
			"			<option value=""365"">In the Last Year</option>" & vbNewLine & _
			"			</select><br>" & vbNewLine & _
			"			<input type=""submit"" name=""btnSubmit"" value=""Search""><br>" &vbCrLf &_		
			"			<a href=""search.asp"">more options</a><br>" &vbCrLf

	call EndTable()	

end sub


sub SearchResults(byval SearchTerm)

	dim strSql, rsCatList, rsResultList, bHasResults
	bHasResults = false
	
	call StartTable("100%", "Search Results for "& SearchTerm)

	strSql = "SELECT CAT_ID, CAT_TITLE "
	strSql = strSql & " FROM " & strMemberTablePrefix & "CMS_CATEGORY"
	strSql = strSql & " ORDER BY CAT_TITLE ASC;"
	
	set rsCatList = my_Conn.Execute(strSql)
				
	do while NOT rsCatList.EOF
		strSql = "SELECT " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CONT_ID, " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CAT_ID, " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CONT_TITLE, " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CONT_SUMMARY "
		strSql = strSql & "FROM  " & strMemberTablePrefix & "CMS_CONTENT, " & strMemberTablePrefix & "CMS_CATEGORY "
		strSql = strSql & "WHERE " & strMemberTablePrefix & "CMS_CONTENT.CAT_ID = " & strMemberTablePrefix & "CMS_CATEGORY.CAT_ID "
		strSql = strSql & "AND " & strMemberTablePrefix & "CMS_CONTENT.CAT_ID = " & rsCatList.Fields("CAT_ID").value & " "
		strSql = strSql & "AND (" & strMemberTablePrefix & "CMS_CONTENT.CONT_TITLE LIKE '%" & SearchTerm & "%' OR " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CONT_BODY LIKE '%" & SearchTerm & "%' OR " 
		strSql = strSql & strMemberTablePrefix & "CMS_CONTENT.CONT_SUMMARY LIKE '%" & SearchTerm & "%')"
		
		set rsResultList = my_Conn.Execute(strSql)
		if NOT rsResultList.EOF then
			bHasResults = true
			Response.Write "<b>"& rsCatList.Fields("CAT_TITLE").Value &"</b><br />"
			do while not rsResultList.EOF
				Response.Write   "				<a href="""& sThisPage &"?ContentID="& rsResultList.Fields("CONT_ID").Value &"&CategoryID="& rsCatList.Fields("CAT_ID").Value &""">"& rsResultList.Fields("CONT_TITLE").Value &"</a><br />" &vbCrLf &_
						"							"& formatStr(rsResultList.Fields("CONT_SUMMARY").Value) &"<br />" &vbCrLf
				rsResultList.MoveNext
				if not rsResultList.EOF then Response.Write("<hr>")
			loop
		end if
		set rsResultList = nothing
		rsCatList.MoveNext	
	loop
	set rsCatList = nothing
	
	if NOT bHasResults then Response.Write "<b>No Results Found</b>"

	call EndTable()
			
end sub


sub DisplayLinks(byval Width)

	'Integrated with Links Manager 3 (Original code by OneWayMule)
	dim strSql, rsPopular, strLink, strLMOrderBy, strLMTitle
	
	if strCMSLMType = "1" then
		strLMTitle = "Latest Links"
		strLMOrderBy = "SHOW=1 ORDER BY POST_DATE DESC, NAME DESC"
	elseif strCMSLMType = "2" then
		strLMTitle = "Most Popular Links"
		strLMOrderBy = "SHOW=1 AND HIT>0 ORDER BY HIT DESC"	
	elseif strCMSLMType = "3" then
		strLMTitle = "Top Rated Links"
		strLMOrderBy = "SHOW=1 AND VOTES>0 ORDER BY RATING DESC, NAME DESC"
	end if

	call StartTable(Width, strLMTitle)

	strSql = "SELECT LINK_ID, NAME, URL FROM " & strTablePrefix & "LINKS WHERE " & strLMOrderBy
    
	Set rsPopular = my_conn.Execute(TopSQL(strSql, strCMSLMCount))
	If NOT rsPopular.EOF Then
		Do While NOT rsPopular.EOF
		
			strLink = "              <a href=""links.asp?action=goto&id=" & rsPopular("LINK_ID") & """ "
			If strLMOpenMethod = "1" Then
				strLink = strLink & " target=""_blank"""
			End If
			strLink = strLink & ">" & rsPopular("NAME") & "</a><br />" & vbNewLine

			Response.Write(strLink)
			
			rsPopular.MoveNext
		Loop
	End If
	rsPopular.Close
	Set rsPopular = Nothing	
		
	call EndTable()

end sub
sub DisplayCalender(byval Width)

	dateHolder = dateValue(strForumTimeAdjust)
	call DrawMonth(dateHolder,1,1,1)
	call TableSpacer(TABLE_SPACER_WIDTH, TABLE_SPACER_HEIGHT)
	call StartTable(Width, "Upcoming Events")
	call WriteUpcomingEvents()	
	call EndTable()				
	call TableSpacer(TABLE_SPACER_WIDTH, TABLE_SPACER_HEIGHT)

end sub

sub StartTable(byval Width, byval Heading)

	Response.Write	"      <table width="""& Width &""" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td bgcolor=""" & strTableBorderColor & """>" & vbNewLine & _
			"            <table width=""100%"" border=""0"" cellspacing=""1"" cellpadding=""4"" align=""center"">" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td align=""center"" bgcolor=""" & strCategoryCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """>"& Heading &"</font></b></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & vbNewLine
			
end sub


sub EndTable()

	Response.Write	"                </font></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"            </table>" & vbNewLine & _
			"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine &_
			"      <table height="""& TABLE_SPACER_HEIGHT &""" cellpadding=""0"" cellspacing=""0"" border=""0"">" & vbNewLine &_
			"        <tr>" & vbNewLine &_
			"		   <td><img src="""& strImageUrl &"clear.gif"" height="""& Height &"""></td>" & vbNewLine &_
			"		 </tr>" & vbNewLine &_
			"      </table>" & vbNewLine
		
end sub

sub NoContent()

	call StartTable("100%", "Error")
	
	Response.Write("You must set a value for 'Homepage Content' in 'CMS Configuration'")
	
	call EndTable()

end sub
Go to Top of Page

soxc
New Member

53 Posts

Posted - 26 October 2003 :  02:27:26  Show Profile
Ok I have found one problem. The change that you made for the "cal_style.asp"is incorrect it should look like the include just above it (not using a <link> tag)

I also noticed other files that are included that are not shipped with the mod (content.asp & inc_contentdisplay.asp). I would open these and make sure that they do not include "inc_adovbs.asp".

My include for the portal.asp page looks like this:

<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp"-->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="cal_functions.asp"-->
<!--#INCLUDE FILE="cal_style.asp"-->

Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 26 October 2003 :  06:55:05  Show Profile
quote:
Originally posted by soxc

I also noticed other files that are included that are not shipped with the mod (content.asp & inc_contentdisplay.asp). I would open these and make sure that they do not include "inc_adovbs.asp".



Pokemon, these are not part of the Portal Mod so I presume you have added something else yourself. Looking at your code you have added something below the main portal article
			%><!--#INCLUDE FILE="includes/virus_scan.asp" --><%
			call DisplayContent (0, 0, 2, 3, 0, 10, 200, 0, 0, 1, 1, 0, "10 B#224;i M#7899;i", 420, "topic.asp")
			

The UK MkIVs Forum
Go to Top of Page

choppermc
New Member

Australia
80 Posts

Posted - 26 October 2003 :  07:15:38  Show Profile  Send choppermc an AOL message
quote:
Originally posted by soxc

I know that config.asp has the include called at the top of the page and should not be removed so it must be another page (like Impact mentioned).




config.asp is an include inside cal_style.asp. So that means by including cal_style.asp into portal.asp you have affectively included config.asp twice.
Correct me if Im wrong.

Oh....Is that it?

Edited by - choppermc on 26 October 2003 07:37:46
Go to Top of Page

soxc
New Member

53 Posts

Posted - 26 October 2003 :  13:10:02  Show Profile
My version of cal_style.asp does not have any includes. If there was a version that did have the include then this would explain the problem.
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 26 October 2003 :  14:20:48  Show Profile
cal_style.asp does not have any includes.
Pokemom, if you include cal_style.asp in the following fashion
<LINK rel="stylesheet" href="cal_style.asp" type="text/css">
i don't think it will parse the ASP correctly, you will need to do it as in the first post

The UK MkIVs Forum
Go to Top of Page
Page: of 3 Previous Topic Topic Next Topic  
Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07