vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   User profile on left *how*? (https://vborg.vbsupport.ru/showthread.php?t=168813)

RickyG 01-26-2008 08:58 PM

User profile on left *how*?
 
hello,
I would like to put the user profile on the left and not on the top in posts. Any idea on how to do this.
Also is it in the user profile field to add more items and have these show up under thier name in the same area on posts?
RickyG

MarkPW 01-26-2008 10:29 PM

In AdminCP, go to vBulletin Options > Style & Language Settings.

Set "Use Legacy (Vertical) Postbit Template" to yes.

RickyG 01-26-2008 10:45 PM

THANK YOU!!!!

That was easy! Here I am thinking I was going to have to play with PHP...WHEW!

Do you know this answer?
Also is it in the user profile field to add more items and have these show up under thier name in the same area on posts?

RickyG

MarkPW 01-27-2008 12:29 AM

You're asking how to add custom fields to the postbit right?

You can do this by either directly editing the postbit_legacy template or using a template hook (the latter of which I prefer because then you don't need to worry about templates reverts in later vb releases and it's easier).

Doing a direct edit would work like so:

Open the postbit_legacy template, find $template_hook[postbit_userinfo_right_after_posts] and below (or above) that, simply add for example:

Code:

<if condition="$post['field3']"><div>Your custom userfield: $post[field3]</div></if>
Repeat as desired to add more fields.

The template hook way:

Add a new plugin at postbit_display_start and add the following code:

Code:

if($post['field3'])
{
        $template_hook[postbit_userinfo_right_after_posts] = '<div>Your custom field: '.$post['field3'].'</div>';
}

if($post['field4'])
{
        $template_hook[postbit_userinfo_right_after_posts] .= '<div>Your custom field: '.$post['field4'].'</div>';
}

Note the .= used in the field4 statement. This appends data to the variable instead of overwriting it.

Hope that helps :)

RickyG 01-27-2008 12:02 PM

Thank you...I just need to gain faith in editing php.
RickyG


All times are GMT. The time now is 07:42 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.02005 seconds
  • Memory Usage 1,714KB
  • 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
  • (2)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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