MyBB Community Forums

Full Version: can i align the text from the profile to be like this?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi, i would like to align the text from profile in virwthread to look like this:

[Image: 25032013102826.png]
Go to PostBit -> postbit_classic ->

Just put <div style="text-align:center">
XXXXXXXXXXXXXXXXXXX
</div>

Where XXXXXXX are your variables for Posts, Reps, etc Wink
not works, i think u misunderstand what i need, i want to have the text aligned from the :

this is how i have it right now

[Image: 25032013143038.png]

and i want to see it aligned like here:

[Image: 25032013102826.png]

this is the forum who have it:

https://forum.mybboard.pl/watek-mybb-sty...-1-5_21185

UP, anyone know how to do this?

for example

[Image: 26032013173255.png]


see what i mean? i want to see the text from the box aligned on :

i dont know how to explain

right now i have it like this:

[Image: 25032013143038.png]

[Image: 26032013174835.png]
Open postbit_author_user and convert it to center-aligned <table> with 1st <td> content right-aligned and 2nd <td> content left-aligned. You'll also need to move postbit_warninglevel and postbit_reputation to the <td>s.

Or you can view their code with firebug and do it with floated <divs>s like they have.
Okay, I understand you.

You need to wrap your variables for Posts, Reputations, etc in a <span> tag.

Put this code: <span style="width: 120px;>XXXXXXX</span>

XXXXXXXX = Your variables.

You need to wrap them individually, like

<span style="width: 120px;>{$post['reputation']}</span>
<span style="width: 120px;>XXXXXXX</span>
<span style="width: 120px;>XXXXXXX</span>
<span style="width: 120px;>XXXXXXX</span>

Do you understand?
(2013-03-27, 02:11 PM)Destroy666 Wrote: [ -> ]Open postbit_author_user and convert it to center-aligned <table> with 1st <td> content right-aligned and 2nd <td> content left-aligned. You'll also need to move postbit_warninglevel and postbit_reputation to the <td>s.

Or you can view their code with firebug and do it with floated <divs>s like they have.

i dont understand and i dont know, and with firebug i see this:
<br/>
<div class="postbit_userinfo">
<div class="uiname">Liczba postów:</div>
<div class="uicontent">498</div>
<div class="uiname">Dołączył:</div>
<div class="uicontent">14.03.2011</div>
<div class="uiname">Wersja MyBB:</div>
<div class="uicontent">1.6.x</div>
<div class="uiname">Reputacja:</div>
<div class="uicontent">

my theme have no <div class="postbit_userinfo">

this is how looks my postbit_author_user
	{$lang->postbit_posts} {$post['postnum']}<br />
	{$lang->postbit_joined} {$post['userregdate']}
	{$post['replink']}{$post['warninglevel']}

(2013-03-27, 02:48 PM)Cedric Wrote: [ -> ]Okay, I understand you.

You need to wrap your variables for Posts, Reputations, etc in a <span> tag.

Put this code: <span style="width: 120px;>XXXXXXX</span>

XXXXXXXX = Your variables.

You need to wrap them individually, like

<span style="width: 120px;>{$post['reputation']}</span>
<span style="width: 120px;>XXXXXXX</span>
<span style="width: 120px;>XXXXXXX</span>
<span style="width: 120px;>XXXXXXX</span>

Do you understand?

Where is have to add that? what file? postbit_classic?
Well do it as table then, I explained every step. Here an example code of postbit_author_user:
<table>
<tr><td align="right">content with :</td><td>the rest</td></tr>
<tr><td align="right">for example {$lang->postbit_posts}</td><td>{$post['postnum']}</td></tr>
</table>
aligns but very bad and the text is moving from his place, creating spaces, even if i play with values is not getting centered how i want

im going to register to their forums and ask them about this

thanks for helps
Well, writing there won't help you if you don't learn basic HTML + how to use MyBB templates.
I used my code (with small CSS additions + few little changes in postbit_classic and postbit_author_user templates more) on localhost default theme and it works just fine:
https://docs.google.com/file/d/0B6pgReiH...JlLXc/edit

EDIT: Here the whole code I used.. but I recommend you to try yourself next time.
<table align="center" style="padding: 10px;">
<tr><td align="right">{$lang->postbit_posts}</td><td align="left">{$post['postnum']}</td></tr>
<tr><td align="right">{$lang->postbit_joined}</td><td align="left">{$post['userregdate']}</td></tr>
<tr><td align="right">{$lang->postbit_reputation}</td><td align="left">{$post['userreputation']}</td></tr>
<tr><td align="right">{$lang->postbit_warning_level}</td><td align="left"><a href="{$warning_link}">{$warning_level}</a></td></tr>
</table>
+ I removed <br /> from postbit_classic after {$post['useravatar']}.
Pages: 1 2