Author |
Topic |
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 08 February 2004 : 10:21:55
|
I'v been playing around with the Message Icons Mod and have a few issues with it at the moment. The one that is bugging me is I can't seem to specify which forums I want to be able to show these icons in.
What I've done is make a copy of icon_blank.gif and renamed it as icon_mi_1.gif which is the default message icon. I've then omitted icon 1 from the code in inc_messsageicons.asp which all works OK.
What I'm trying to do now is hide the icons available in post.asp for selected forums by using:if intAllowedCategoryMsg then
%>
<!--#INCLUDE FILE="inc_messageicons.asp" -->
<%
end if
I've tried to put an array of 'allowed forums' in inc_header.asp but can't get it to work. Why won't this work?intAllowedCategoryMsg = Array("50","51","52","53","54","55","56","57","58") |
Edited by - ruirib on 08 February 2004 10:33:53 |
|
laser
Advanced Member
Australia
3859 Posts |
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 09 February 2004 : 02:05:35
|
You mean I should remove the double "" around each Forum ID no.?
Also should I use: if Forum_ID = intAllowedCategoryMsg |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 09 February 2004 : 02:51:39
|
quote: You mean I should remove the double "" around each Forum ID no.?
Yes
quote: Also should I use: if Forum_ID = intAllowedCategoryMsg
Not that I'm aware of, I'd do something like :
For x = 0 to UBound(intAllowedCategoryMsg)
If Forum_ID = intAllowedCategoryMsg(x) Then
blnForumCheck = Yes
x = UBound(intAllowedCategoryMsg)
End If
Next
If blnForumCheck Then ...
If the boolean doesn't work, just use an integer. |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 09 February 2004 : 03:33:48
|
Thanks Laser, I'll give it a try tonight. |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 09 February 2004 : 17:45:44
|
Laser, it doesn't show in post.asp in any forum. I used: inc_header.aspintAllowedCategoryArray = Array(50,51,52,53,54,55,56,57,58) post.aspFor x = 0 to UBound(intAllowedCategoryArray)
If Forum_ID = intAllowedCategoryArray(x) Then
blnForumCheck = Yes
x = UBound(intAllowedCategoryArray)
End If
Next
If blnForumCheck Then
%>
<!--#INCLUDE FILE="inc_messageicons.asp" -->
<%
end if
What do you mean by use an integer instead? |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 10 February 2004 : 00:51:18
|
Use as integer :
For x = 0 to UBound(intAllowedCategoryArray)
If Forum_ID = intAllowedCategoryArray(x) Then
blnForumCheck = 1
x = UBound(intAllowedCategoryArray)
End If
Next
If blnForumCheck = 1 Then
%>
<!--#INCLUDE FILE="inc_messageicons.asp" -->
<%
end if
|
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 10 February 2004 : 04:25:51
|
Still doesn't show for all forums. Any ideas? |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 10 February 2004 : 04:35:44
|
Does it show it Forum 50 ? Have you got the code in the proper spot ? Example URL and username ? |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 10 February 2004 : 05:03:50
|
No, doesn't show in forum 5O or 51 etc
www.stephendoyle.net/post.txt text version of post.asp - look for line 950 www.stephendoyle.net U:snitz P:snitz If you use post2.asp in your url it will show how the icons appear.
|
Edited by - StephenD on 10 February 2004 05:05:33 |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 10 February 2004 : 15:23:50
|
snitz user doesn't have access to forum 50+
You just want this MOD available in some forums, correct ? |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 10 February 2004 : 17:29:38
|
Sorry about that. I thought I changed it but checking it now it seems I've got some 3.4.04 upgrade problems with post.asp and post_info.asp that I missed, namely edit forums doesn't work and post_info page gets stuck after hitting submit. I'll have to get back to you on this when I fix it up.
But yes, I only want the msg icons available for the forum no.s in that array. |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 11 February 2004 : 17:08:01
|
OK, I've fixed up post_info.asp and post.asp to work properly. Laser, if you are around, can you retry that array please. |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 12 February 2004 : 03:23:53
|
Your code is fine, but you need to change Forum_ID to strRqForumID |
|
|
StephenD
Senior Member
Australia
1044 Posts |
Posted - 12 February 2004 : 05:24:48
|
Excellent Laser, works perfect. I can think of lots of other applications for this code now too.
Cheers Mate! |
|
|
laser
Advanced Member
Australia
3859 Posts |
Posted - 12 February 2004 : 05:28:57
|
no prob, you threw me with the Forum_ID variable at first, but not your fault - I should have checked the code further |
|
|
|
Topic |
|