vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Administrative and Maintenance Tools - vBMQN - Moderation Queue Notifications + Desktop App (https://vborg.vbsupport.ru/showthread.php?t=294999)

Lee Roberts 02-10-2013 11:00 PM

vBMQN - Moderation Queue Notifications + Desktop App
 
1 Attachment(s)
****


Introduction
There are many scenarios where this mod would come in handy for administrators. There are too many for me to cover them all, so I will give you the scenario this mod was developed for...

If you have a hand full of moderating staff and a large number of forums, adding each moderator to each forum can be quite a pain, however doing it that way would give you notifications for those moderators when something dose need their attention from within those said forums...

Another option would be to setup staff to be Global Moderators, this removes the need to add them to specific forums but it also removes queue notifications because moderators wouldn?t be assigned to individual forums...

We require new members to be moderated and/or that their first submissions to the forum require moderating, this can become quite a pain because again staff would need to continually check the moderation queue for new items...

The Solution and Requirements
What we need is moderation queue notifications via email and possibly a desktop app for those staff that would rather not use their email/inbox.

Features:
- Email Notifications for multiple users/addresses
- Notifications for every item type (posts, threads, attachments etc.)
- Email sending using the vB mail method/system (plain text emails)
- Email generation should use the vB Phrase system (multi-language support)
- Automated checking of the moderation queue (vB Cron system)
- Should support the Scheduled Task log system (debugging, report actions taken)
- Support for external applications and their development (xml based status)

All of the above are present in the first release of this mod (v1), please see the screen shots.

This mod is setup as a vB Cron task; I could not see/find a better way to make this an automated system working with anything else from within the vB system. By default the Cron task is setup to run every 30 minutes, if you would like to adjust this, simply go in and adjust the Cron job as you wish.

Desktop App
At the moment I am still developing a windows (.net) desktop app to work with this, right now we don?t have a big need for this so it?s not a priority for me to develop this and get it out to you any time soon, when the moderation queue is checked regardless of its current state the included xml file is updated to reflect this. So all your own app would need to do is read in this xml file and take the action you require.

If there is a massive interest in the desktop app for this I could be persuaded to push it to the top of my job list, for now though it is work in progress and with no planned deadline or release date.

Support
We have been using this mod in a production environment for almost 12 months now with no problems at all, it is really quite a simple mod and I?m surprised it hasn?t been done already, given the number of requests I have seen.

I will support this as best I can, I am a busy guy so you will need to understand this if you do run into any problems and request support.

Install/Upgrade
Installing this mod is much like any other, upload the files in the download to the same locations on your server, import the product xml file, go to the Admin > Settings > Options > vBMQN: General Options page and configure as you wish. If you are upgrading from an older version simply follow the same steps as installing for the first time.

Change Log
v1.0 - 11 Feb 2013
- First version

v2.0 - 12 Feb 2013
- Added support for table prefix's ( config.php > $config['Database']['tableprefix'] = ''; )
- Rewrite of the database query code, now uses the vB Database Class ( $vbulletin->db->query_first )
- Changed from the use of the php "number_format" function to the vB function "vb_number_format"
- Added instant email notification rather than sending emails to the vB mail queue ( $notsubscription = true )

Enjoy!
This has helped us allot and I hope those of you who have requested this before find it to be ?just the job? as well.

Regards,
Lee Roberts

Lee Roberts 02-11-2013 02:04 PM

** Reserved **

Dont forget to mark as Installed, Nominate and Rate/Vote for it !

.Me

Bluemax712 02-11-2013 07:36 PM

Installed on a vB4.20 test forum with only this mod installed
but no luck so far getting it to send email notifications

The Scheduled Task Log viewer shows vBMQN "Queue Checked"evertime it is run
but never shows a "Notification Sent" even though there are messages waiting in the mod queue.
The Sendmail log shows no activity or errors.

Have also tried manually running the Process E-Mail Queue and then vBMQN scheduled tasks with same results.

Lee Roberts 02-11-2013 08:25 PM

Hi,

Humm that is a strange one, i've used the "$notsubscription = true" in my code and this means "do not use the mail queue and send immediately" so i dont think its that.

How is the test forum setup to send mail? my test forum is setup to use SMTP for sending mail, however your cron log is telling you "Queue Checked" not "Notification Sent"...

What settings have you used for the Admin > Settings > Options > vBMQN: General Options page?

.Me

Bluemax712 02-11-2013 08:38 PM

for vBMQN General Options:
- Moderator Control Panel (tried leaving blank and using modcp)
- Email Notification: Yes
- Notification Recipients: testmod@server.al.home
(this email works when sending a test message via VBulletin CP)
-Desktop Notification: Yes (but also tried No)

I've tried setting to SMTP too
and enabling/disabling the Email Queue system
and trying with and without the -f parameter

test messages from the CP -send test email to all users - work fine.

Lee Roberts 02-11-2013 08:47 PM

Have you got another email address you can test with, i am wondering if there is an issue with the "dots" in that address?

Will see if i can replicate this now...

I just used that email address on my test forum and i got "Notification Sent".

The email was also recived by my mail server.

What items do you have in your mod que at the momment?

.Me

Bluemax712 02-11-2013 09:31 PM

I've just been creating new "threads" everytime for testing -
it shows the awaiting messages count increase in the the admin control front status page under Threads to Moderate

I've then been running the vBMQN cron script manually

Don't have any other emails to try yet
only user@server.al.home type of emails addreses work for now with my setup
- vBulletin gives me "invalid email address" if I try to set a user's address to : user@localhost
though it does work if I mail from the command line

EDIT:
Installed on another server 4.1.12 (production) which has a few other plugins installed
inc Glowhost Spam-O-Matic + FractalizeR and a few others.

I get this error when running the vBMQN cron script manually

================================================== ================================================== ===============================

vBMQN

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 23

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 26

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 29

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 32

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 35

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in [path]/includes/cron/vbmqn.php on line 38
Queue Checked
Done
================================================== ================================================== ===============================

Edit 3: Also tried installing it on a test vB 3.8.7 with FractilezeR installed - got no errors when running the vBMQN script
but same results as the test vB4 server receive no emails
- Scheduled Task log only shows "vBMQN Queue Checked" (never says Emails Sent)

Edit4 : noticed if I purposely set the "modcp" setting to the wrong name - nothing changes - no errors shown
everything functions same

Jeromedia603 02-11-2013 11:38 PM

This could be a great mod! Spot Reserved for when I have time to take a better look!

Bluemax712 02-12-2013 12:24 AM

Quote:

Originally Posted by Jeromedia603 (Post 2403625)
This could be a great mod! Spot Reserved for when I have time to take a better look!

I know- can only pray will be able to get this to work
thanks much Lee :)

Bluemax712 02-12-2013 03:37 AM

Not sure if I'm the only one having trouble and only know basics of programming but ...
Since it's only version 1.0 - it would be cool if could add a debug function to print out all the variables on a separate page while it's running :)

Lee Roberts 02-12-2013 10:44 AM

Hi guys,

I dont think any other mods would/will give this mod any problems its far to simple for that and the info it needs from the database is unlikely to change unless vB make an update or change and i really cant see that happening.

The "Moderator Control Panel" setting dose nothing more then setup the link in the email that you recive, you should have this set to "modcp" unless your moderator control panel is in a folder with another name.

Your welcome, hopefully I can make this happen for you.

Lee

Bluemax712 02-12-2013 12:51 PM

Thanks for the quick response Lee! Sent you a PM with the output

Lee Roberts 02-12-2013 08:29 PM

Hi,

Today it was clear I needed to do some more work on this mod as it was failing for people, today I have released version 2 and would like you to download and install this version.

Please see the "Change Log" section of the main description for the things that have been done. Version 2 also fix's the problems apsrfvb4 has been having, so generally version 2 is better, sorry for any inconvenience!

Thanks,
Lee

Bluemax712 02-12-2013 10:39 PM

Everything works perfect now Lee
Thanks so much for this awesome mod.

Installed on a 4.1.12 PL2 and a 4.2.0 PL3 server

cdoyle 02-15-2013 03:21 PM

Just installed, waiting for some moderated posts now :)

One thing for the next version that would be nice is to have an option so it just sends to all moderators.

cdoyle 02-15-2013 05:55 PM

OK,
I've gotten a couple moderated alerts, not quite how but I would like to change the URL in the email to something like this instead

http://www.caraudiocentral.net/forums/moderation.php

That way, I (or my mods) have the ability to ban the users as spammers etc.

I can't do that from the modcp.

deadlySniper 02-15-2013 08:24 PM

Tagged

I will wait to see further development before I deploy this on my site.

Great work!

Lee Roberts 02-16-2013 09:03 PM

Quote:

Originally Posted by cdoyle (Post 2404474)
OK,
I've gotten a couple moderated alerts, not quite how but I would like to change the URL in the email to something like this instead

http://www.caraudiocentral.net/forums/moderation.php

That way, I (or my mods) have the ability to ban the users as spammers etc.

I can't do that from the modcp.

Hi,

Thanks for the feedback, details below to change the email body:

Goto: AdminCP > Languages & Phrases > Phrase Manager

From there change "Phrase Type:" to "Email Body Text", on the list that gets presented to you, look for "vbmqn" and choose "Edit" on the right for that Phrase, on the next page you will see it says "Text" and to the right of that you can see the default email body text:

Quote:

Hello,

The moderation queue on $vboptions[bbtitle] has items waiting to be moderated.

Moderator Control Panel: $vboptions[bburl]/$vboptions[vbmqn_modcpdir]/index.php

All the best,
$vboptions[bbtitle] Admin
Under this section you will see a blank white input box, the title for this section of the page is called "Translations", to change the URL in the email you would add into the blank white box the below text:

Quote:

Hello,

The moderation queue on $vboptions[bbtitle] has items waiting to be moderated.

Moderator Control Panel: http://www.caraudiocentral.net/forums/moderation.php

All the best,
$vboptions[bbtitle] Admin
If you wanted to you could change this text to:

Quote:

Hello,

The moderation queue on $vboptions[bbtitle] has items waiting to be moderated.

Moderator Control Panel: $vboptions[vbmqn_modcpdir]

All the best,
$vboptions[bbtitle] Admin
and then from the options page for this mod, where you would normally put the name of the folder for the moderator control panel i.e "modcp" you could actually put the full url to the "moderation.php" file/page, so this would be "http://www.caraudiocentral.net/forums/moderation.php".

Doing it the later way would mean you dont need to navigate through the Phrase Manager every time you want to change this url, though i would probably consider this to be a "set and forget", so not somthing that would require change too often. The choice is yours really.

.Me

Lee Roberts 02-16-2013 09:04 PM

Quote:

Originally Posted by deadlySniper (Post 2404501)
Tagged

I will wait to see further development before I deploy this on my site.

Great work!

Hi Ryan,

Thank you for your feedback, what kind of things would you like to see from its development?

.Me

cdoyle 02-16-2013 10:06 PM

Quote:

Originally Posted by Lee Roberts (Post 2404679)
Hi,

Thanks for the feedback, details below to change the email body:

Goto: AdminCP > Languages & Phrases > Phrase Manager

From there change "Phrase Type:" to "Email Body Text", on the list that gets presented to you, look for "vbmqn" and choose "Edit" on the right for that Phrase, on the next page you will see it says "Text" and to the right of that you can see the default email body text:



Under this section you will see a blank white input box, the title for this section of the page is called "Translations", to change the URL in the email you would add into the blank white box the below text:



If you wanted to you could change this text to:



and then from the options page for this mod, where you would normally put the name of the folder for the moderator control panel i.e "modcp" you could actually put the full url to the "moderation.php" file/page, so this would be "http://www.caraudiocentral.net/forums/moderation.php".

Doing it the later way would mean you dont need to navigate through the Phrase Manager every time you want to change this url, though i would probably consider this to be a "set and forget", so not somthing that would require change too often. The choice is yours really.

.Me

Perfect!
Thank You!

weave 02-17-2013 01:02 PM

This looks great, tagging for when I have some time to test this one

deadlySniper 02-18-2013 12:33 AM

Quote:

Originally Posted by Lee Roberts (Post 2404680)
Hi Ryan,

Thank you for your feedback, what kind of things would you like to see from its development?

.Me

For app that you have planned
  • Manage Moderation
    • Accept
    • Ignore
    • Delete
  • Ban User If Spam
  • Popup Alert
  • Manage vBMQN Settings

Zip File
Just advise. Put the include folder that it contains in a folder called upload. I know there are some users out there that not up to speed on everything.

Lee Roberts 02-18-2013 08:42 AM

Quote:

Originally Posted by deadlySniper (Post 2404885)
For app that you have planned
  • Manage Moderation
    • Accept
    • Ignore
    • Delete
  • Ban User If Spam
  • Popup Alert
  • Manage vBMQN Settings

Good Morning Ryan,

Ok, well for the app the plan is for this to just be a notification tool. So no management features are planned in that sense, there will be some vBMQN settings for things like the URL of the xml file i.e www.example.com/forums/includes/xml/vbmqn.xml so the app would know where to look for updates, notifications and queue status.

Quote:

Originally Posted by deadlySniper (Post 2404885)
Zip File
Just advise. Put the include folder that it contains in a folder called upload. I know there are some users out there that not up to speed on everything.

Well spoted, i will change the zip when/if there will be an update.

.Me

Zakalway 02-21-2013 07:16 AM

Would it be possible to include reported posts from a reported post forum in the notifications? That would be amazing.

Lee Roberts 02-21-2013 09:25 AM

Quote:

Originally Posted by Zakalway (Post 2405543)
Would it be possible to include reported posts from a reported post forum in the notifications? That would be amazing.

Humm,

Possibly yes, however I?m thinking it may be better to just have reported posts put into the moderation queue anyway, when they get reported.

What do you think?

.Me

Foxx. 02-21-2013 11:00 PM

installed on 4.2.0 PL2 did receive email however after deleting the test posting I am still receiving emails notifying me that the queue needs attention. ie; there is still posts there that need to be looked at when in fact there are none. do I have a setting wrong?

also: this seems to not be the case and is a byproduct of the repeated emails I am receiving
changelog
v2.0 - 12 Feb 2013
Quote:

- Added instant email notification rather than sending emails to the vB mail queue ( $notsubscription = true )

Foxx. 02-21-2013 11:01 PM

Quote:

Originally Posted by Zakalway (Post 2405543)
Would it be possible to include reported posts from a reported post forum in the notifications? That would be amazing.

just "subscribe" to the "Reported Posts" forum and you will automatically receive an email to your account on file.

Zakalway 02-22-2013 12:41 AM

Quote:

Originally Posted by Foxx. (Post 2405685)
just "subscribe" to the "Reported Posts" forum and you will automatically receive an email to your account on file.

...I'm an idiot. Thank you so much. Is there a way to get these emails sent instantly? I only see subscribe through control panel or email weekly or daily.

Lee Roberts 02-22-2013 09:54 AM

Quote:

Originally Posted by Foxx. (Post 2405684)
installed on 4.2.0 PL2 did receive email however after deleting the test posting I am still receiving emails notifying me that the queue needs attention. ie; there is still posts there that need to be looked at when in fact there are none. do I have a setting wrong?

also: this seems to not be the case and is a byproduct of the repeated emails I am receiving
changelog
v2.0 - 12 Feb 2013

That is a strange one, a setting from this mod's options wouldnt do this. Instant email notification was actually present in version 1, i just forgot to document it, so added it to the change log to highlight it better for the guys upgrading...

Try running the repair and optimize wizard (AdminCP > Maintenance > Repair / Optimize Tables), i dont know if that will fix something for you or not but its the only thing i can think of doing, the mod dose a very simple database query and then performs an action based on the returned results, the results will be a 0 or a number above, there really is'nt any other way (that i know of) for the script/mod to think there is items waiting, it only knows this from something in the database telling it there is items waiting.

Quote:

Originally Posted by Zakalway (Post 2405691)
...I'm an idiot. Thank you so much. Is there a way to get these emails sent instantly? I only see subscribe through control panel or email weekly or daily.

By default vB treats anything "subscription" based as a lower priority, so these types of email always go to the email queue, you could install a MOD to stop this (if one exists) or you could turn off the "Mailqueue System" (AdminCP > Settings > Options > Email Options

Quote:

Use Mailqueue System
When enabled, subscription emails generated by your site will be processed in batches to lessen the load on your server. Account activation, lost passwords and other vital emails are sent instantly regardless of this setting. If your site has low traffic, subscription emails may be delayed.
I'm thinking of making another MOD that puts Reported Posts into the mod que at the point of those posts being reported, its really simple and easy to do. If a user reports a post, then they are asking for a member of staff to review that post, so it makes sense to me that it should happen that way.

.Me

deadlySniper 02-22-2013 02:50 PM

Quote:

Originally Posted by Lee Roberts (Post 2405752)
By default vB treats anything "subscription" based as a lower priority, so these types of email always go to the email queue, you could install a MOD to stop this (if one exists) or you could turn off the "Mailqueue System" (AdminCP > Settings > Options > Email Options

Or what I did was just change the cron times. Made it run more often. This is if your host is decent since cron can make the site run slow

Quote:

Originally Posted by Lee Roberts (Post 2405752)
I'm thinking of making another MOD that puts Reported Posts into the mod que at the point of those posts being reported, its really simple and easy to do. If a user reports a post, then they are asking for a member of staff to review that post, so it makes sense to me that it should happen that way.

.Me

Kudos, if you need help I can offer to be a contributor or supporter

Zakalway 02-22-2013 09:33 PM

Quote:

I'm thinking of making another MOD that puts Reported Posts into the mod que at the point of those posts being reported, its really simple and easy to do. If a user reports a post, then they are asking for a member of staff to review that post, so it makes sense to me that it should happen that way.
I'd love to see something like that for the Notifications Bar and would be happy to support it financially.

Lee Roberts 02-22-2013 10:27 PM

Quote:

Originally Posted by deadlySniper (Post 2405792)
Kudos, if you need help I can offer to be a contributor or supporter

Thanks for the offer will contact you now via skype.

Quote:

Originally Posted by Zakalway (Post 2405874)
I'd love to see something like that for the Notifications Bar and would be happy to support it financially.

Thanks for the feedback, will contact you via PM now about this. When the time comes i will start a new thread where we can discuss what will be a new mod.

.Me

Bluemax712 02-23-2013 01:30 AM

Moving flagged posts to the Mod queue sounds interesting Lee - if can limit to certain groups
-some forum users would be flagging everything if they had that power:)

I'm currently using FractilizeR to show Moderator notifications
which I combine with yours to also email them.

Are you thinking about doing your own version to do everything?

Lee Roberts 02-23-2013 10:26 AM

Quote:

Originally Posted by apsrfvb4 (Post 2405908)
Moving flagged posts to the Mod queue sounds interesting Lee - if can limit to certain groups
-some forum users would be flagging everything if they had that power:)

I'm currently using FractilizeR to show Moderator notifications
which I combine with yours to also email them.

Are you thinking about doing your own version to do everything?

I'm not sure at the momment, giving it some thought as to the best way of going about this.

.Me

wildheart 02-26-2013 12:45 PM

Thank you for this mod. I really hoped that it will send a pm to the mods as well?

wildheart 02-26-2013 01:06 PM

It shows that the e-mail was sent at 15:41 and it is now 16.06 and not one of the e-mail addresses have received anything yet?

Lee Roberts 02-26-2013 02:43 PM

Quote:

Originally Posted by wildheart (Post 2406455)
Thank you for this mod. I really hoped that it will send a pm to the mods as well?

Thanks for the feedback, i will make a note of that request.

Quote:

Originally Posted by wildheart (Post 2406460)
It shows that the e-mail was sent at 15:41 and it is now 16.06 and not one of the e-mail addresses have received anything yet?

Do you have active visitors browsing your forum, i ask because this MOD runs via a cron task and cron tasks only get processed as people visit pages of your forum?

Be sure to have a space inbetween each email address, can you access your servers mail logs to make sure the emails did leave the server?

.Me

My Hattiesburg 02-27-2013 05:13 AM

Quote:

Originally Posted by Lee Roberts (Post 2405551)
Humm,

Possibly yes, however I?m thinking it may be better to just have reported posts put into the moderation queue anyway, when they get reported.

What do you think?

.Me

That's a great idea. There was a mod for 3.8 that did this but it wasn't updated for 4.2.

Lee Roberts 02-27-2013 03:55 PM

Quote:

Originally Posted by My Hattiesburg (Post 2406638)
That's a great idea. There was a mod for 3.8 that did this but it wasn't updated for 4.2.

Hi,

Thanks for the feedback, i know i think i may have seen it the other day. Leave it all with me guys, i'm going dark for a few days while i work on a custom MOD for some one, after that i hope to drop a few mods on here that cover some of the things we are talking about and some others :).

.Me

Bluemax712 02-27-2013 09:17 PM

One other thing would be cool Lee - if it could also send out a message when the queue has been cleared.


All times are GMT. The time now is 06:25 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01441 seconds
  • Memory Usage 1,893KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (27)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete