Back to vBulletin Tips & Tricks

New block in the member profile
by cionfs 01 Feb 2009
Rating: (4 votes - 5.00 average)

I happen to want to experience some features of vBulletin. I tried to recreate a box in the personal profile. In short add a box like the ones in the picture below.



To add an additional block go to AdminCP> Styles and Templates> Search in Templates and search for models MEMBERINFO. Once we found double-click on the mouse to change it.
Inside there is the code. To find this

Code:
<div id="sidebar_container">
    <!-- sidebar -->
    $template_hook[profile_right_first]
    $blocks[stats_mini]
    $template_hook[profile_right_mini]
    $blocks[friends_mini]
    $blocks[albums]
    $template_hook[profile_right_album]
    $blocks[groups]
    $blocks[visitors]
    $template_hook[profile_right_last]
    <!-- / sidebar -->
</div>
To add a new block is needed this code

Code:
<!--new block-->
<!-- $id -->
<div id="$id" class="tborder content_block">
    <h4 class="thead block_title">
        <a href="#top" class="collapse_gadget" onclick="return toggle_collapse('$id')"><img id="collapseimg_$id" src="$stylevar[imgdir_button]/collapse_generic{$vbcollapse['collapseimg_'.$id]}.gif" alt="" border="0" /></a>
        <a name="$id"></a>
        <span class="block_name">BLOCK TITLE</span>
    </h4>
    <div class="block_content" id="collapseobj_$id" style="{$vbcollapse['collapseobj_'.$id]}"><div class="alt1 smallfont block_row block_footer">
<p align="center">
CONTENT
</p>
</div></div>
</div>
<!-- / $id -->
<!--new block-->
You should get something like this

Code:
<div id="sidebar_container">
    <!-- sidebar -->
    $template_hook[profile_right_first]
    $blocks[stats_mini]
<!--new block-->
<!-- $id -->
<div id="$id" class="tborder content_block">
    <h4 class="thead block_title">
        <a href="#top" class="collapse_gadget" onclick="return toggle_collapse('$id')"><img id="collapseimg_$id" src="$stylevar[imgdir_button]/collapse_generic{$vbcollapse['collapseimg_'.$id]}.gif" alt="" border="0" /></a>
        <a name="$id"></a>
        <span class="block_name">BLOCK TITLE</span>
    </h4>
    <div class="block_content" id="collapseobj_$id" style="{$vbcollapse['collapseobj_'.$id]}"><div class="alt1 smallfont block_row block_footer">
<p align="center">
CONTENT
</p>
</div></div>
</div>
<!-- / $id -->
<!--new block-->
    $template_hook[profile_right_mini]
    $blocks[friends_mini]
    $blocks[albums]
    $template_hook[profile_right_album]
    $blocks[groups]
    $blocks[visitors]
    $template_hook[profile_right_last]
    <!-- / sidebar -->
</div>
In this way you will have a result like this:



PS: Sorry for my English

vblts.ru supports vBulletin®, 2022-2024