The Arcive of vBulletin Modifications Site. |
|
Simple [img] word wrap bbcode Details »»
|
|||||||||||||||||||||||||||||
I saw a few threads in the modification graveyard where you can add a bbcode to align an image left or right, did not see any newer threads that accomplish this correctly and without messing up the signature and other things.
This is what I've done: First lets add some CSS entries to each style. In admin cp, go to Styles & Templates -> Style Manager -> Main CSS Options Scroll down to the Additional CSS Definitions and add the following at the bottom: Code:
img.alignright {
padding: 4px;
margin: 0 0 2px 7px;
display: inline;
}
img.alignleft {
padding: 4px;
margin: 0 7px 2px 0;
display: inline;
}
.alignright {
float: right;
}
.alignleft {
float: left
}
Second lets add the bbcodes: Title: Image Align Left BB Code Tag Name: IMGLEFT Replacement: Code:
<img class="alignleft" border="0" alt="" src="{param}" />
Use {option}: no Title: Image Align Right BB Code Tag Name: IMGRIGHT Replacement: Code:
<img class="alignright" border="0" alt="" src="{param}" />
Use {option}: no Lastly, lets edit the postbit templates for each style: Find: Code:
$template_hook[postbit_signature_start] Code:
<TABLE width="100%" style="border-collapse: collapse; border: none;">
<tr>
<td class="alt1">
Code:
$template_hook[postbit_controls] <!-- / controls --> </div> Code:
</td>
</tr>
</table>
Thats it! You're done. I'll attach some buttons I made which you can use when adding your new bbcode if you wish. Download Now
Screenshots
Show Your Support
|
|||||||||||||||||||||||||||||
| Comments |
|
#2
|
||||
|
||||
|
thanks
|
|
#3
|
|||
|
|||
|
doesn't work just replaces image with " />
|
|
#4
|
||||
|
||||
|
That's odd. Did you copy all the code and follow the directions 100%? What version of vb?
|
|
#5
|
||||
|
||||
|
I'm getting the same issue. VB 3.8.4
|
|
#6
|
|||
|
|||
|
Example?
|
|
#7
|
|||
|
|||
|
Does this work?
|
|
#8
|
|||
|
|||
|
Nice mod! Is there one which aligns an image as yours does, but also allows for a caption underneath?
|
|
#9
|
|||
|
|||
|
Example?
|
|
#10
|
|||
|
|||
|
Good mod, working on my 3.8.4 board, but can anyone help with the question above? We really need this.
|
![]() |
|
|