vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Design and Graphics Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=253)
-   -   How to center username and user title? (https://vborg.vbsupport.ru/showthread.php?t=312428)

thetechgenius 06-25-2014 11:00 PM

How to center username and user title?
 
I would like to know how to center the Username and Usertitle on the profile page?

Does anyone know how to do this? I know it is done in "additional.css", but I don't know the CSS do add. Could anyone please help me?


Here is a screenshot of my profiles:

https://vborg.vbsupport.ru/external/2014/06/16.png

--------------- Added [DATE]1403741319[/DATE] at [TIME]1403741319[/TIME] ---------------

I think I might have posted this in the wrong place. My mistake, sorry about that.

I have just created this thread in the "Unpaid" section. Could a Mod or Admin please close this thread? Thank you.

TheLastSuperman 06-26-2014 02:43 AM

Try adding in this css to additional.css:

Code:

/* center avatar, username, title, rank, userinfo_extra, postbit_reputation, imlinks */
.postbitlegacy .userinfo .username_container, .postbitlegacy .userinfo .rank, .postbitlegacy .userinfo .usertitle .imlinks {
        text-align:center;
}

.postbitlegacy .userinfo .postuseravatar, .postbitlegacy .userinfo .postuseravatar img {
        float:none;
        text-align:center;
}

.postbitlegacy .userinfo .usertitle {
        display: block;
        float:none;
        text-align:center;
        clear: both;
}

.postbitlegacy .userinfo .userinfo_extra {
        text-align:center;
        clear: both;
}

.postbit_reputation {
        float:none;
        text-align:center;
}

.postbitlegacy .imlinks  {
        float:none;
        text-align:center;
}

.postbitlegacy .after_content {
        clear:right !important;
}

The very top snippet was provided to me by Lynne many many many moons (years ago) so credit to her as she did it first :cool:.

thetechgenius 06-26-2014 03:40 AM

Quote:

Originally Posted by TheLastSuperman (Post 2503795)
Try adding in this css to additional.css:

Code:

/* center avatar, username, title, rank, userinfo_extra, postbit_reputation, imlinks */
.postbitlegacy .userinfo .username_container, .postbitlegacy .userinfo .rank, .postbitlegacy .userinfo .usertitle .imlinks {
        text-align:center;
}

.postbitlegacy .userinfo .postuseravatar, .postbitlegacy .userinfo .postuseravatar img {
        float:none;
        text-align:center;
}

.postbitlegacy .userinfo .usertitle {
        display: block;
        float:none;
        text-align:center;
        clear: both;
}

.postbitlegacy .userinfo .userinfo_extra {
        text-align:center;
        clear: both;
}

.postbit_reputation {
        float:none;
        text-align:center;
}

.postbitlegacy .imlinks  {
        float:none;
        text-align:center;
}

.postbitlegacy .after_content {
        clear:right !important;
}

The very top snippet was provided to me by Lynne many many many moons (years ago) so credit to her as she did it first :cool:.

Thank you so much!

It seems to solved most of the centering issues. However, the usertitle is still not centered on the Profile page. You should know that I have setup images for the User Titles, and not text. I don't know if that matters or not. Its not a Mod though, I have <img src="URL"> in the User Title boxes in the AdminCP.

Here is the direct link to my Profile Page on my site: https://thetechgenius.net/members/1-TheTechGenius

tbworld 06-26-2014 04:49 AM

This should not be done with inline CSS. However, it was not cooperating on a remote page and I did not have the extra time to spend on it. This will get you going for now. :)

Edit your template and make the following change.

Search for:
Code:

  <span class="usertitle">
Replace:
Code:

  <span style="display:inline-block; text-align:center;" class="usertitle">

thetechgenius 06-27-2014 02:56 AM

Quote:

Originally Posted by tbworld (Post 2503807)
This should not be done with inline CSS. However, it was not cooperating on a remote page and I did not have the extra time to spend on it. This will get you going for now. :)

Edit your template and make the following change.

Search for:
Code:

  <span class="usertitle">
Replace:
Code:

  <span style="display:inline-block; text-align:center;" class="usertitle">


I edit the MEMBERINFO template, correct?

I did what you said, and still nothing. I tried everything to get this centered. I am really about to give up, and just leave it like that.

Thank you for helping me though, I greatly appreciated!

tbworld 06-27-2014 09:29 AM

Quote:

Originally Posted by thetechgenius (Post 2503981)
I edit the MEMBERINFO template, correct?

I did what you said, and still nothing. I tried everything to get this centered. I am really about to give up, and just leave it like that.

Thank you for helping me though, I greatly appreciated!

If you have loaded some kind of modification that is manipulating the template cache then it might be overriding your edits in MEMBERINFO. Also, make sure you are selecting the correct "parent" style to edit. Unfortunately, the only thing I could do is use firebug to observe your style and to create those changes. So I am only seeing the exported code to my browser.


All times are GMT. The time now is 02:17 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.00986 seconds
  • Memory Usage 1,735KB
  • 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
  • (6)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete