vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How to Center Posbit: Username, Usertitle, and Avatar (https://vborg.vbsupport.ru/showthread.php?t=312138)

Yummie 06-14-2014 04:55 AM

How to Center Posbit: Username, Usertitle, and Avatar
 
How do you center ONLY the username, usertitle, and avatar in vB3.8.7 postbit? The rest would be left aligned to the left :)

Sorry if this already exist.

ShawneyJ 06-15-2014 05:38 AM

i use to use the <center tags, but dont work with some browsers.
so i tested out <div align="center"> and works a treat.

if you wrap the <div align="center"> </div> around each bit of coding you want centered, then it will work for you to.

first off, are you using post bit legacy ?

if you look at this code and search in post bit legacy and compare with yours. you can see where i have placed the center tags.
for what you want to work.

Code:

                        <div align="center"><div id="postmenu_$post[postid]">
                                <if condition="$show['profile']">
                                <a class="bigusername" href="member.php?$session[sessionurl]u=$post[userid]">$post[musername]</a>
                                <script type="text/javascript"> vbmenu_register("postmenu_$post[postid]", true); </script>
                                <else />
                                $post[musername]
                                </if></div></div>


                        <div align="center"><if condition="$post['usertitle']"><div class="smallfont">$post[usertitle]</div></if></div>
                        <div align="center"><if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if></div>
                        <div align="center">$template_hook[postbit_userinfo_left]</div>

                        <div align="center"><if condition="$show['avatar']">
                                <div class="smallfont">
                                        &nbsp;<br /><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" $post[avwidth] $post[avheight] alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
                                </div>
                        </if></div>


Yummie 06-19-2014 04:43 AM

Quote:

Originally Posted by ShawneyJ (Post 2502015)
i use to use the <center tags, but dont work with some browsers.
so i tested out <div align="center"> and works a treat.

if you wrap the <div align="center"> </div> around each bit of coding you want centered, then it will work for you to.

first off, are you using post bit legacy ?

if you look at this code and search in post bit legacy and compare with yours. you can see where i have placed the center tags.
for what you want to work.

Code:

                        <div align="center"><div id="postmenu_$post[postid]">
                                <if condition="$show['profile']">
                                <a class="bigusername" href="member.php?$session[sessionurl]u=$post[userid]">$post[musername]</a>
                                <script type="text/javascript"> vbmenu_register("postmenu_$post[postid]", true); </script>
                                <else />
                                $post[musername]
                                </if></div></div>


                        <div align="center"><if condition="$post['usertitle']"><div class="smallfont">$post[usertitle]</div></if></div>
                        <div align="center"><if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if></div>
                        <div align="center">$template_hook[postbit_userinfo_left]</div>

                        <div align="center"><if condition="$show['avatar']">
                                <div class="smallfont">
                                        &nbsp;<br /><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" $post[avwidth] $post[avheight] alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
                                </div>
                        </if></div>


Thank you so much!


All times are GMT. The time now is 07:48 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.01037 seconds
  • Memory Usage 1,732KB
  • 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)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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