Back to vBulletin 4.x Template Modifications

Dynamic License Plate & Text in Postbit.
Mod Version: 1.00, by demo7up

vB Version: 4.0.0 Rating: (1 vote - 5.00 average) Installs: 6
Released: 05 Dec 2011 Last Update: Never Downloads: 0
Not Supported Template Edits  

~~~~~MARK INSTALLED~~~~~~

Here is it is for all Car Enthusiast Site's all i ask is that you link back to my site in way, shape or form. Site: http://www.nycjdm.com Or please throw a donation my way I will not help support this unless you have marked this installed, can either send me a link with the link back to my site or have placed a donation.

This Mod should work for any vB 4.+

So first we need to setup the CSS for the custom div that positions the License Plate & Text

so
1. Navigate to Admin CP => Styles & Templates => Style Manager => Edit Templates => CSS Templates => additional.css

At the bottom of this file add (you can change the css to match your site width etc..

Code:
div.jdm_plate{
height:66px;
}
div.jdm_plate p {
padding-top: 25px;
margin: 0 auto;
font-size:24px;
text-transform:uppercase;
color:black;
}
2. Navigate to AdminCP => User Profile Fields =>Add New User Profile Field

You will need to create 2 fields, one to Select License Plates the Other to Add the Text to it.

So create the first custom field we will call this x (make sure u get the field id)
Code:
Profile Field Type: Single Selection Menu
Title: License Plate
Description: Please choose your License Plate from the drop down list above. If you do not see yours listed please request them <a href="www.yoursite.com/your_forum_for_requests">here.</a>
<br/>
<img src="path-to/license_plates/Japan.png" alt="Japan" />
<img src="path-to/license_plates/New_York.png" alt="NY" />
Options: Now this is case sensitive and each option must be named exactly like the corresponding image so for me its: 
Japan
New_York
The Second Profile Field we will call y (make sure u get the field id)
Profile Field Type: Single-Line Text
Title: License Plate Text
Description: Enter your License Plate Text Here.
Max length of allowed user input: 6 or 7
Default Value: What ever you want up to 6 or 7 Characters.
Now save that ... Hopefully you have both Field Id's and now on to the next step


3. Navigate to Admin CP => Styles & Templates => Style Manager => Edit Templates => Postbit Templates => postbit_legacy

find and place code between the code in the box or place it where you would like it to show in the post bit.

Code:
</vb:if> 
{insert bottom code here}
<vb:if condition="$post['userid']">
Display Code make sure you change the X and Y to the correct profile id's

Code:
<vb:if condition="$post['userid']">
<vb:if condition="$post['fieldxx']">
    <div class="jdm_plate" style="background-image:url(http://path-to/license_plates/{vb:raw post.fieldxx}.png);">
<p><b>{vb:raw post.fieldyy}</b></p>
</div>
</vb:if> 
</vb:if>
Note: Blank License Plates can be found @ http://www.blankplates.com/

Download

No files for download.

Screenshots

Click image for larger version
Name:	image1.png
Views:	620
Size:	32.4 KB
ID:	134855   Click image for larger version
Name:	image2.jpg
Views:	503
Size:	31.3 KB
ID:	134856  

Similar Mods

Add-On Releases North American License Plate vBulletin 4.x Template Modifications

vblts.ru supports vBulletin®, 2022-2024