vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Conditionals. To Display something from a usergroup (https://vborg.vbsupport.ru/showthread.php?t=204889)

6piston 02-11-2009 09:41 AM

Hi Dismounted

thanks for the rpely
i'm not really sure what you're saying but,

the plugin works just fine. it's just that i want to display only avatars from paid subscribers(through their usergroup)

but the contionals just doesn't work, i've also added into the plugin, but to no avail.
maybe i'm doing it wrongly?

Lynne 02-11-2009 02:13 PM

I could be that the usergroupid is not available at the place you are trying to use it. Or, it has a different name. I didn't go look through the code to find out. Go look and see where $thread is defined and see if the usergroupid was grabbed at the same time in the query. If not, you may have to write a query to grab it based on $thread['userid']

6piston 02-11-2009 02:36 PM

Got it.

Would you know of any other plugin or mods residing in the forumdisplay or threadbit which requires the need to grab usergroups? It would help me learn the codes from there

As for writing queries, can you point me in the right direction to do so? i'd really love to get the plugin working for my purpose

any help is much appreciated!

Thanks!
Tom

Lynne 02-11-2009 04:56 PM

This is on the forumdisplay.php page, right? You are wanting to put the thread starters avatar next to the thread on the page? But, you only want to display the avatar if the thread starter is a paid subscriber - it has nothing to do with the user *viewing* the page, right?

The query that grabs the thread info is around line 878 of forumdisplay. There is a hook right above it for you to grab the user.usergroupid. You will have to add a join as well as the field. The hook location is 'forumdisplay_query'.

6piston 02-12-2009 04:01 PM

hi lynne

thanks for the advice!

deluxmall 11-20-2009 10:16 PM

I like to know the same thing, any solution?


All times are GMT. The time now is 01:32 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.01362 seconds
  • Memory Usage 1,717KB
  • 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)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete