MOD help-Banner Image Reward - Postet den (1706 Views)
Junior Member
The Zim
Innlegg: 107
107
Well, because I can't get my hands on Crash's Member Award MOD, I decided to attempt to write my own [IMG]http://i607.photobucket.com/albums/tt158/The_Zim/Emoticons/rollseyes.gif[/IMG]. But, I really don't know much about asp, [IMG]http://i607.photobucket.com/albums/tt158/The_Zim/Emoticons/Loudedt.gif[/IMG], so I will probably end up blowing something up before I'm done, dead. But anyways...
I'm going to base this new MOD off of the Avatars MOD (I'll give credit!) with some minor/major changes. (minor as in it doesn't change a whole lot, major as in it will change a lot of the overall functioning).
To the point, lol. For now, all I need is a basic line of code that only allows admins to change something. I would like the banners to be chosen by the admins and selected to be displayed by them as well, via the user's profile who earned them. I would like it to work like the Member Level field that is already there, but I can't find the right code. I've been searching in pop_profile.asp. Please help if you can bigsmile
   
 Sidestørrelse 
Postet den
Advanced Member
Carefree
Innlegg: 4224
4224
Easy enough.
Code:

'	This restricts function to administrators only ...
if mLev > 2 then	'	Excludes moderators, regular members, guests
' Take whatever action you want restricted, put all of your code here
else
' Do nothing
end if
Postet den
Advanced Member
Etymon
Innlegg: 2396
2396
Hey Zim,

I have some of Crash's older stuff. Contact me via my signature (if the pop_mail.asp here at Snitz is still under repairs).
Cheers,

Etymon
Postet den
Forum Moderator
AnonJr
Innlegg: 5768
5768
Huw's fixed the pop_mail.asp here so he should be able to e-mail you via the normal process.
Postet den
Junior Member
The Zim
Innlegg: 107
107
I sent the email, thx! I'll probably still try and make the MOD just to give something back, lol, and because I want to see if I can actually do it, lol. So, we'll see what blows up first bigsmile
With that code. If I want it to literally do nothing, can I just leave it like it is? (change the code for admins only, of course, but make it so nothing happens if they are not an admin) Can I just delete the 'Do Nothing in there and put that in? Or even leave that part be?
Postet den
Advanced Member
Etymon
Innlegg: 2396
2396
Hey Zim,

I'm sending you all of the Crash MODs I have. If I remember correctly, Crash extracted these MODs from his own modified forum, so you will have to pay close attention to some of the variables especially the colors. There should be about 10 MODs in the e-mail I am sending, and the .zip file is just over 1MB. If your e-mail provider won't allow that large of a file, let me know, and I'll post a link or perhaps just upload them to SnitzBitz as a package for others to have as well.
Postet den
Junior Member
The Zim
Innlegg: 107
107
Ok, my email provider allows up to 20 mb, so that shouldn't be a problem, you ought to upload any of those that aren't already on Snitzbitz on there, that way if anyone else needs them, the MODs are there for them.
Postet den
Junior Member
The Zim
Innlegg: 107
107
Ok, just to make sure. Most code that starts with strsql = strsql & ", " or anything similar, is just more of "server information" where the script tells the browser to retrieve such and such information from the server right? I need to know whether or not they would appear on the page to a normal user if I do not enclose them with that admin only code you gave me earlier.
Anything that has Response.write with it is what is going to appear to normal users, right? Unless it is enclosed with the admin only script?
Unfortunately, I can't learn new things with asp like I could with HTML, just playing around with different script and seeing what happens in a preview, lol. Does anyone know of a program that would let me preview an asp page without having to upload it to my host first?
Postet den
Advanced Member
Etymon
Innlegg: 2396
2396
You'd probably find quicker help on how to code at some other web sites. The forums here at Snitz references this link: http://www.4guysfromrolla.com/webtech/faq/ under URLs and Other Resources.
Postet den
Junior Member
The Zim
Innlegg: 107
107
I got that email, thx Etymon! bigsmile As for those sites, for some unknown reason, they have that 4 guys from rolla site blocked here at my school. I don't know why, but they do. They have a lot of sites blocked for no reason angry. It makes my web surfing a pain the rear sad but I manage somehow, lol. I do most of my coding and stuff here at school, but I'll have to check into that site when I'm at home. cool
Postet den
Support Moderator
Shaggy
Innlegg: 6780
6780
Try W3Schools.
Search is your friend “I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
 
Du må legge inn en melding