![]() |
Displaying Profile Fields
Does anyone know how to display Profile Fields in threads, below Join Date & Posts ?
http://img141.imageshack.us/img141/8...cf9b19baad.png |
There are currently no hooks to add info where you want to in Beta 10 or 11.
|
A new template hook was added for next release.
For the moment, you can edit the template manually or modify the template cache. |
Quote:
whats the code for it {vb:raw userinfo.field8} {vbrawphrase customerfield.field8} which is what i am asking, as i have looked through the code and can't find a solution for manual entry |
Well the template is: conversation_userinfo
And in that template current posts are: Code:
{vb:raw conversation['userinfo']['posts']} Code:
{vb:raw conversation['userinfo']['joindate']} Code:
{vb:raw conversation['userinfo']['field8']} |
I tought the same, but... the fields are not included in conversation variable.
|
Quote:
|
I agree, fields are part of user's information (userinfo).
Currently only user table is included, I think they forgot to join userfield table. I hope it is not by design. |
<a href="http://tracker.vbulletin.com/browse/VBV-5021" target="_blank">http://tracker.vbulletin.com/browse/VBV-5021</a>
|
Quote:
|
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 |
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. |
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}} 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 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. |
Quote:
thank you, this was the info i needed, i will do some tests today |
All times are GMT. The time now is 07:22 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|