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 DEV-Group
 DEV Bug Reports (Closed)
 (v3.4.02) missing </font>/extra quotes/default.asp
 Forum Locked  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

pweighill
Junior Member

United Kingdom
453 Posts

Posted - 04 September 2002 :  18:15:58  Show Profile
The following lines 513-525 of default.asp contain 2 <font> tags and 1 </font> tag.
An extra </font> tag needs adding (shown here in red)


Response.Write	" bgcolor=""" & strForumCellColor & """ valign=""top"">" & _
		"<font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><span class=""spnMessageText""><a href="""
if ForumFType = 0 then
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
else 
	if ForumFType = 1 then
		Response.Write	ForumURL & """ target=""_blank"""
	end if
end if 
Response.Write	""">" & chkString(ForumSubject,"display") & "</a></span></font><br />" & _
	"<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & _
	formatStr(ForumDescription) & _
	"</font></td>" & vbNewline


The "" in red on line 519 is extra and should be removed.

It is resulting in ...target="_blank"">... in the HTML code.

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 05 September 2002 :  04:07:02  Show Profile
Instead of doing that, it would be better to apply the spnMessageText class to the Forum Description as well (since we now allow ForumCode to be used in the Forum Description, and someone might put a URL in there).

change lines #514 - #525 from this:

		"<font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><span class=""spnMessageText""><a href="""
if ForumFType = 0 then
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
else 
	if ForumFType = 1 then
		Response.Write	ForumURL & """ target=""_blank"""
	end if
end if 
Response.Write	""">" & chkString(ForumSubject,"display") & "</a></span><br />" & _
		"<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & _
		formatStr(ForumDescription) & _
		"</font></td>" & vbNewline


to this:

		"<font face=""" & strDefaultFontFace & """ color=""" & strForumFontColor & """ size=""" & strDefaultFontSize & """><span class=""spnMessageText""><a href="""
if ForumFType = 0 then
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
else 
	Response.Write	ForumURL & """ target=""_blank"
end if 
Response.Write	""">" & chkString(ForumSubject,"display") & "</a><br />" & _
		"<font size=""" & strFooterFontSize & """>" & _
		formatStr(ForumDescription) & _
		"</font></span></font></td>" & vbNewline

Go to Top of Page

davemaxwell
Access 2000 Support Moderator

USA
3020 Posts

Posted - 05 September 2002 :  08:12:44  Show Profile  Visit davemaxwell's Homepage  Send davemaxwell an AOL message  Send davemaxwell an ICQ Message  Send davemaxwell a Yahoo! Message
Can I ask a question that's been bugging me for a while? Why do we have this type of code:


if ForumFType = 0 then
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
else 
	if ForumFType = 1 then
		Response.Write	ForumURL & """ target=""_blank"
	end if
end if 


We only have two types of forums(a forum and a URL) right now, so it seems kinda silly to do this double check. All this code would need to be is this:

if ForumFType = 0 then
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
else 
	Response.Write	ForumURL & """ target=""_blank"
end if 


Is there a reason for the double check which just hasn't dawned on me yet? Seems like we're doing extra work we don't need too (this type of double check is in multiple places throughout the code....)

Dave Maxwell
Barbershop Harmony Freak
Go to Top of Page

Deleted
deleted

4116 Posts

Posted - 05 September 2002 :  10:14:52  Show Profile
I'd better use select-case statement, this would ease any further development in case a new forum type is added.


select case ForumFType
case 0
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
case 1
	Response.Write	ForumURL & """ target=""_blank"
case else
	'error: invalid forum code as of v3.4.x
end select


Stop the WAR!

Edited by - Deleted on 05 September 2002 10:18:48
Go to Top of Page

davemaxwell
Access 2000 Support Moderator

USA
3020 Posts

Posted - 05 September 2002 :  10:47:02  Show Profile  Visit davemaxwell's Homepage  Send davemaxwell an AOL message  Send davemaxwell an ICQ Message  Send davemaxwell a Yahoo! Message
quote:
Originally posted by bozden

I'd better use select-case statement, this would ease any further development in case a new forum type is added.


select case ForumFType
case 0
	Response.Write	"forum.asp?FORUM_ID=" & ForumID
case 1
	Response.Write	ForumURL & """ target=""_blank"
case else
	'error: invalid forum code as of v3.4.x
end select





There's no need for this right now. It just seems like a waste to do the extra if check since there is only two valid values. That's why I asked...

Dave Maxwell
Barbershop Harmony Freak
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 05 September 2002 :  16:27:43  Show Profile
fixed above. (removed the extra check for ForumFType).
Go to Top of Page

davemaxwell
Access 2000 Support Moderator

USA
3020 Posts

Posted - 05 September 2002 :  17:21:12  Show Profile  Visit davemaxwell's Homepage  Send davemaxwell an AOL message  Send davemaxwell an ICQ Message  Send davemaxwell a Yahoo! Message
Thanks. One less thing on the "bug me" list....

Dave Maxwell
Barbershop Harmony Freak
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 05 September 2002 :  17:41:53  Show Profile
I also removed 2 other instances of that extra check. One that was around line #504 and the other that was around line #546
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 16 September 2002 :  00:12:28  Show Profile
fixed in v3.4.03
Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.21 seconds. Powered By: Snitz Forums 2000 Version 3.4.07