The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
does this already exist?
hello - new to vB hacking and wondering if such a hack already exists:
i want moderators to be able to flag certain posts (not threads) that will show as a count under the persons username. for example, person x has 10 flagged posts, person y has 1 flagged posts. is it out there? or should i roll up my sleeves and start hacking? |
#2
|
||||
|
||||
I don't think it exists but it also wouldn't be that hard.
Just create a new field in the `post' table, `flag' for example, which will be 1 or 0. Index that field too. Then add a button in postbit which will only be visible to mods, and will take them to misc.php or whatever that will update this `flag' field. Then it's just a matter of counting the number of posts that are flagged in the post tbale. |
#3
|
|||
|
|||
that's great - thanks for the direction.
|
#4
|
|||
|
|||
can i get some more direction? how can i add another postbit icon? i'm not sure where to add it.
|
#5
|
||||
|
||||
In the postbit template.
|
#6
|
|||
|
|||
thanks, i've added the flag to the database, and the items to the postbit templates.
i've got two additional questions: 1) in the postbit template, how can i get an image to show up only when the post is flagged? 2) is the best place to put the sql code in misc.php or a new php (eg. flag.php)? |
#7
|
|||
|
|||
i've answered my second question (i created flag.php) but the first one is still there - how can i get an image to show up only when the flag field in the post table is set to "1"?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|