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

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: MOD Implementation
 Poll Mod - How do I restrict it to only Admins?
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Rasyr
Junior Member

USA
199 Posts

Posted - 19 April 2002 :  12:28:20  Show Profile
Davio,
You have seen the forums I set up. I am wondering what changes I would have to make to which files to show the "Add Poll" link only to those marked as Admins?


**TANSTAAFL**

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 22 April 2002 :  16:31:26  Show Profile
It's easy. The Add Poll link only appears on the forum.asp and topic.asp pages. You can search for "Add Poll" in those files and find the code for them. The links are displayed if AdminAllowed = "1". You can change that to if mLev = "4".

If you can't get it right, post a link to a txt version of your topic.asp and forum.asp files. I would check the code on my computer but I don't have the old code anymore as I am working on the new version of the poll mod.

«------------------------------------------------------»
Want to know when the next version comes out,
as soon as possible? Join our Mailing Lists !
Go to Top of Page

Rasyr
Junior Member

USA
199 Posts

Posted - 24 April 2002 :  21:42:27  Show Profile
Thanks!! That worked like a charm. Now I don't have to worry about the odd moderator creating polls....



**TANSTAAFL**
Go to Top of Page

[DISA]Jumpman
Junior Member

Denmark
137 Posts

Posted - 20 July 2002 :  01:23:50  Show Profile  Visit [DISA]Jumpman's Homepage
quote:

It's easy. The Add Poll link only appears on the forum.asp and topic.asp pages. You can search for "Add Poll" in those files and find the code for them. The links are displayed if AdminAllowed = "1". You can change that to if mLev = "4".

If you can't get it right, post a link to a txt version of your topic.asp and forum.asp files. I would check the code on my computer but I don't have the old code anymore as I am working on the new version of the poll mod.



Mine don't work i have try to chance this code in forum.asp

<% if Cat_Status = 0 or Forum_Status = 0 then
if (AdminAllowed = 1) then %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_locked.gif" alt="Kategori Låst" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a><br>
<% ' #################### Poll Mod ##################### %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Add Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% ' ################################################### %>
<% else %>
<img src="icon_folder_locked.gif" alt="Category Locked" height=15 width=15 border=0> Kategori Låst
<% end if
else
if Forum_Status <> 0 then %>
<% ' #################### Poll Mod ##################### %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_new_topic.gif" alt="Nyt Emne" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a>
<% if (strUserPolls = "1") or (AdminAllowed = 1) then %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Ny Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% end if
' ################################################### %>
<% else %>

to

<% if Cat_Status = 0 or Forum_Status = 0 then
if (mLev = 4) then %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_locked.gif" alt="Kategori Låst" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a><br>
<% ' #################### Poll Mod ##################### %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Add Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% ' ################################################### %>
<% else %>
<img src="icon_folder_locked.gif" alt="Category Locked" height=15 width=15 border=0> Kategori Låst
<% end if
else
if Forum_Status <> 0 then %>
<% ' #################### Poll Mod ##################### %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_new_topic.gif" alt="Nyt Emne" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a>
<% if (strUserPolls = "1") or (AdminAllowed = 1) then %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Ny Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% end if
' ################################################### %>
<% else %>


But it don't work plz help me
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 20 July 2002 :  02:30:04  Show Profile
quote:


Mine don't work i have try to chance this code in forum.asp

<% if Cat_Status = 0 or Forum_Status = 0 then
if (AdminAllowed = 1) then %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_locked.gif" alt="Kategori Låst" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a><br>
<% ' #################### Poll Mod ##################### %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Add Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% ' ################################################### %>
<% else %>
<img src="icon_folder_locked.gif" alt="Category Locked" height=15 width=15 border=0> Kategori Låst
<% end if
else
if Forum_Status <> 0 then %>
<% ' #################### Poll Mod ##################### %>
<a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="icon_folder_new_topic.gif" alt="Nyt Emne" height=15 width=15 border=0></a> <a href="post.asp?method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Nyt Emne</a>
<% if (strUserPolls = "1") or (AdminAllowed = 1) then %>
 <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>"><img src="pin.gif" alt="Ny Poll" height=15 width=15 border=0></a> <a href="post.asp?poll=1&method=Topic&FORUM_ID=<% =Forum_ID%>&CAT_ID=<% =Cat_ID%>&Forum_Title=<% =ChkString(Forum_Subject,"urlpath") %>">Ny Poll</a>
<% end if
' ################################################### %>
<% else %>


But it don't work plz help me

You changed the wrong one. The code in red is what you need to change.

«------------------------------------------------------»
What new features are going to be in the 3.4
version? See the 3.4 UnOfficial Features List !
Go to Top of Page

[DISA]Jumpman
Junior Member

Denmark
137 Posts

Posted - 20 July 2002 :  04:24:16  Show Profile  Visit [DISA]Jumpman's Homepage
Thanks now it's works



Go to Top of Page
  Previous Topic Topic Next Topic  
 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.42 seconds. Powered By: Snitz Forums 2000 Version 3.4.07