The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Code Review
Hi, I have been working on an internal project for my forum for a little while now, and have just about finished up. However, before I put all of it live I was hoping to have a few pros take a look and let me know if I borked anything up. It all works like it is supposed to work, but that doesn't mean it will work effciently on a high volume server.
The Project Goals:
What has been done: I have completed the first task. I used group memberships and the built-in promotion routine to assign users to a new group based on time, posts and rep. If the members are present in the group I display a check box below the standard Report screen. I modified report.php with the following block of code PHP Code:
Now for part two. Part two required that I make one more change to report.php. I added a boolean parameter to let the reportitem class know that a spam report was made. PHP Code:
I first change the function structure. I set a default value as to not upset any other calls that wouldn't know about the new boolean parameter. PHP Code:
I replaced: PHP Code:
PHP Code:
Here are the changes that deal with a post in an existing report: replaced: PHP Code:
PHP Code:
I apologize if this isn't the proper way to go about this, but I am still learning. Any tips or suggestions (or critisims) would be appreciated. There is some front end security measures put in place that only allow members to to "flag as spam" when the author has 5 posts or less. However, I fear this could easily be defeated with anything that intercepts the http stream. All you would have to do is know the variable name and value. I suppose the user doing it would get caught soon thereafter, but still a concern. Would the standard procedure be to just do a second check of credentials on the server side? |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|