vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Mod Q Question (https://vborg.vbsupport.ru/showthread.php?t=208485)

Markro 03-16-2009 02:56 AM

Mod Q Question
 
I have a couple links for Admin only in the header of my community boards. The links are "Threads" "Post", they link to the Thread moderation q and the posts moderation q. Is it possible to format the URLS so the display the current volume of pending threads in each que?

For example:

Currently:

Threads - Posts

New:

Threads (0) - Posts (5)

To the right of the link it will display the pending threads to be moderated.

Any suggestions?

Thank you for any assistance you may be able to provide.

Lynne 03-16-2009 03:07 AM

Take a look in the modifications area cuz I am pretty sure I've seen a mod for this. Do a search on "moder*" or similar in "all mods" "titles only"

Markro 03-16-2009 03:17 AM

Thanks.

I found a couple threads:

https://vborg.vbsupport.ru/showthrea...light=moder%2A
https://vborg.vbsupport.ru/showthrea...light=moder%2A

I'm going to add them here in case other users are in-search of a similar functionality.

I figured it would be a minor template variable, I have no interest in installing a modification for this (I like to keep my community modification free).

Thank you very much for your advice Lynne, always a pleasure.

TigerC10 03-16-2009 03:28 AM

You'll definitly have to create a plugin. You can use this code for a plugin...

PHP Code:

$getmodqueue $db->query_read("SELECT type FROM " TABLE_PREFIX "moderation WHERE type != 'groupmessage'");
while (
$queue $db->fetch_array($getmodqueue))
{
    
$moditems[$queue['type']]++;
}

$queue_post vb_number_format($moditems['reply']);
$queue_thread vb_number_format($moditems['thread']); 

Then use a vb phrase to construct it in your template. Here's a couple phrase tips:

https://vborg.vbsupport.ru/showthread.php?t=117132
https://vborg.vbsupport.ru/showthread.php?t=98047

EDIT:
Guess I couldn't reply fast enough, you've found alternative solutions. :)

Lynne 03-16-2009 03:37 AM

I don't think you can do this without a plugin. TigerC10 wrote a nice one, I have one similar on my forum. You would have to use a plugin because the information is not available unless you query for it.

Markro 03-17-2009 01:35 AM

Thank you TigetC10 and Lynne for your assistance :)


All times are GMT. The time now is 02:30 AM.

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.01044 seconds
  • Memory Usage 1,723KB
  • 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
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete