The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
I'm looking for a way to limit bbcode font sizes in 3.8.x. I don't want to disable bbcode font size completely. But, I'd like to allow a maximum of size "4." Here's what I've tried so far:
But, so far, nothing has worked on my test board. Does anybody have a method? Or any ideas as to why what I've tried isn't working? Thanks ![]() |
#2
|
||||
|
||||
![]()
I was pretty sure it was in vbulletin_textedit.js. Exactly what did you change in there?
You could always use replacement variables: Find: <font size="7"> Replace with: <font size="1"> (Punish those that try to go around the system. ![]() |
#3
|
|||
|
|||
![]()
In the textedit.js I tried both changing the font sizes for the 5-7 cases to the size for case 4 and removing cases 5-7 completely. Here is what it's like now (starting at line 2078):
PHP Code:
As for replacement variables, I was trying bbcode not html. Maybe that's why it didn't work? I'll try html too. Thanks ![]() |
#4
|
||||
|
||||
![]()
You need to use html in the replacement variables. If you look in the source code, it actually says "<font size="7">"
Maybe in the file, instead of deleting the lines for the various cases, just return 1 and see what happens. ie: PHP Code:
|
#5
|
|||
|
|||
![]()
No luck on the textedit.js. But the replacement variable thing worked with html tags instead. Thanks.
![]() Will the replacement variable effect anything else other than the bbcode? Like I used a 7pt or 7px font somewhere in a skin? I haven't noticed anything yet, I'm just wondering for future reference. |
#6
|
||||
|
||||
![]()
The replacement variables will effect the entire site. However, I don't know that <font size="7"> (or 6 or 5) is used anywhere else in default vbulletin (try a search in your templates to see), so I think it will only effect your posts. If you are worried about it though, you would write a little plugin that just does a str_replace in the posts for those terms.
|
#7
|
|||
|
|||
![]()
The replacement variables are fine for now. But that sounds like a nice little project to get my feet wet in coding a plug myself.
Thanks again ![]() |
#8
|
||||
|
||||
![]()
I know this is a 3-year bump, but I'm hopefully adding something useful...
I've been needing this for a while myself. Like the OP, I'd tried a number of things, and none quite worked. This thread was helpful (filled in the gaps), but I had to read it several times over, because it didn't make a lot of sense in chronological order. I write a lot of guides, mostly as notes to myself, and I put one together for this: How to Change bbcode font sizes in vBulletin In addition to simply changing or removing sizes, you can also add some styling with the replacement variables, by inserting divs. I like to add a margin of at least 5-10px before the larger fonts, because they tend to be used as subheadings. I mentioned that in the guide, and I wanted to add it here, too. I also did not find any font size="7" (4,5,6) tags in templates or in my mods/plugins. However keep that last one in mind -- plugins and mods. Because I do know of some that have size references. I don't think "size=number" is valid HTML, which is why it won't be in any themes. Thanks, Lynne and mme24. ![]() |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|