vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB5 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=263)
-   -   Displaying Profile Fields (https://vborg.vbsupport.ru/showthread.php?t=288491)

TheSupportForum 10-10-2012 02:41 PM

and info on how to add custom profile fields to conversation_userinfo yet ?

in the hooks and manual entry if possibe please

this is going back to the previous convo here
https://vborg.vbsupport.ru/showpost....46&postcount=5

BirdOPrey5 10-12-2012 10:57 AM

You can check up on the bug report: http://tracker.vbulletin.com/browse/VBV-5021

There won't be a fix until the "Fix Version" on that page is listed as a released version number (Alpha 14 for example.)

On the plus side it was recently revised up in priority but no estimate when it will happen.

Also, there are no "hooks" in VB5 so there will never be a "hooks" way of doing things anymore.

There will only be template edits or file extensions.

nhawk 10-12-2012 08:02 PM

Since they added a template hook to the conversation_userstats template this is possible in Beta 13.

In this example, the 'Location' field will be displayed.

1) Create a new template. In this example I'll use the name TestTemplate.
Product: vBulletin (or your product)
Style: Default (or your style)
Title: TestTemplate
Template:
Code:

{vb:data posterinfo, user, fetchUserinfo, {vb:raw posterid}}
{vb:raw posterinfo.field2}


2) Go to ACP->Products & Hooks->Manage Hooks and click 'Add New Hook'.
Product: vBulletin (or your product)
Hook Location: conversation_userstats
Title: Test Hook
Execution Order: 10
Template Name: TestTemplate
Hook Arguments:
Code:

posterid=conversation.userid
Click Save

Refresh a thread in your forum and you'll see the Location being displayed for each poster.

There IS a drawback with this method. A database query is added for EVERY POST in a thread. That is not good, and I would wait for the JIRA report mentioned above to be fixed.

TheSupportForum 10-13-2012 10:49 AM

Quote:

Originally Posted by nhawk (Post 2372589)
Since they added a template hook to the conversation_userstats template this is possible in Beta 13.

In this example, the 'Location' field will be displayed.

1) Create a new template. In this example I'll use the name TestTemplate.
Product: vBulletin (or your product)
Style: Default (or your style)
Title: TestTemplate
Template:
Code:

{vb:data posterinfo, user, fetchUserinfo, {vb:raw posterid}}
{vb:raw posterinfo.field2}

2) Go to ACP->Products & Hooks->Manage Hooks and click 'Add New Hook'.
Product: vBulletin (or your product)
Hook Location: conversation_userstats
Title: Test Hook
Execution Order: 10
Template Name: TestTemplate
Hook Arguments:
Code:

posterid=conversation.userid
Click Save

Refresh a thread in your forum and you'll see the Location being displayed for each poster.

There IS a drawback with this method. A database query is added for EVERY POST in a thread. That is not good, and I would wait for the JIRA report mentioned above to be fixed.



thank you, this was the info i needed, i will do some tests today


All times are GMT. The time now is 09:46 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.00994 seconds
  • Memory Usage 1,728KB
  • 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
  • (4)bbcode_code_printable
  • (1)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
  • (4)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