The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Quick Delete Avatar - Fairly easy I think
Ok, this seems like a wierd hack request at first, but it makes sence!
I would like a hack that puts a link under the avatar, that will remove that persons avatar. I have an Off site avatar hack installed now. It makes it so i have a field# (field7 in my case) in the database be the avatar link. This is the off site avatar hack I have installed. It works awsome, and if you use the little addition MarkB made for it, (posted on 2nd page) if the field is blank it just doesnt display anything for an avatar. So in short, I am not smart enough to know how to make a link that will clear a field for a userID. Then i can just put it in the postbit. I think it should be as easy as that. But i could be wrong. |
#2
|
||||
|
||||
hmm, you can clear userfields from within your acp,
but ok, here's how you'd do it: open admin/functions.php find PHP Code:
PHP Code:
all you have to do now is to open member.php and put after this: PHP Code:
PHP Code:
|
#3
|
||||
|
||||
Thanks for the code, but it doesnt seem to be showing up in the postbit at all. I can't seem to find where the code has an error, or where i am setting it up incorrectly. I tried installing it... then i retried it, but still to no avail. I don't think it works 100% ^^
Any sugestions on why? Wait!, i got it! Sry, my bad... It works great. One small thing, can i have it check to see if the field is blank, somthing like check[field7]='' dont show link else showlink haha, my l33t php coding skills at their best Also, just checking, but this DOES do a check to make sure that your an admin/mod correct? |
#4
|
||||
|
||||
Looking at his code, it does check.
For the "check if the field isn't empty, show link if it isn't, else don't show it" check, instead of adding: PHP Code:
PHP Code:
|
#5
|
||||
|
||||
you rock link!
but one small thing PHP Code:
PHP Code:
|
#6
|
||||
|
||||
you're welcome |
#7
|
||||
|
||||
how would i make this avaliable to MOD's too?
i tried changing the code in members.php from: PHP Code:
PHP Code:
|
#8
|
||||
|
||||
instead of the OR's you have to use AND's
|
#9
|
|||
|
|||
I don't mean to but into someone elses thread but Ive been trying to come up with a better way to delete Avatars on the site then going through one by one. I have installed the Avatar Gallery hack so I can see all the avatars that have been uploaded to the site and I know which ones I want to delete. I can manage to place the $removeavalink where I want it to go but when I run it I get an error stating
Database error in vBulletin 2.3.0: Invalid SQL: UPDATE userfield SET field7='' WHERE userid=5941 mysql error: Unknown column 'field7' in 'field list' mysql error number: 1054 Date: Saturday 12th of July 2003 01:09:54 AM Script: http://www.newcelica.org/forums/foru...va&userid=5941 Referer: http://www.newcelica.org/forums/show...threadid=89749 |
#10
|
||||
|
||||
larry, you cannot use this thread's tips if you haven't installed the off site avatar hack, as it's directly based on this hack
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|