• This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

BB Code Manager

Status
Not open for further replies.
worked perfect! Final table question...I notice the width of my columns vary based on the length of the column heading. What's the best way to standardize the column width? I could add spaces but it seems a bit sloppy.

PS. Thanks principia. I have Excel but am trying to create an example for those who do not.
 
You will need another BB Code with an option and then use that for the column header.
Something like [th=50]Text[/th] - where 50 is the number of pixels.

The html code would be something like:
Code:
<td style="width: {1}px">
 
worked perfect! Final table question...I notice the width of my columns vary based on the length of the column heading. What's the best way to standardize the column width? I could add spaces but it seems a bit sloppy.

PS. Thanks principia. I have Excel but am trying to create an example for those who do not.

You can use Open Office or Libre Office, they are free
 
Unfortunately, that is a feature being developed for the next version. Workaround: if possible create a .pdf / .swf file that takes up only a few pixels.

I was good with your reply and then I realized that for the MEDIA bb code, there seems to be the exact workaround in place that I desire. Instead of a YouTube video appearing which would take up a lot of space, a single line appears:
Code:
[SIZE=4][B][MEDIA=site] - Embedded Media[/MEDIA][/B][MEDIA=site][/media][/SIZE][MEDIA=site]Embeds media from approved sites into your message. It is recommended that you use the media button in the editor tool bar. Approved sites: [URL='http://www.dailymotion.com/']Daily Motion[/URL]; [URL='http://www.facebook.com/']Facebook[/URL]; [URL='http://video.google.com/']Google Video[/URL]; [URL='http://www.twitvid.com/']Twitvid[/URL]; [URL='http://www.vimeo.com/']Vimeo[/URL]; [URL='http://www.youtube.com/']YouTube[/URL];
[LIST]
[*]Example:
 [MEDIA=youtube]oHg5SJYRHA0[/MEDIA]
 Output:
 [I]An embedded YouTube player would appear here.[/I]
 [/media]
[/LIST]
[MEDIA=site]
How does that happen for the MEDIA bb code?
 
hmm...this is strange. When I go to edit the above post, I see the full content which I posted. When I view it now, I only see a single bullet point from what I copied/pasted, and the text I typed after is not appearing. I'll leave it in tact and see if it is a bug with XF.
 
That's because you've used the media tags for the content.

Use the code box instead.

The existing BB Code isn't entered on the help page in the same way KK has done for custom BB Code.

If you want to achieve the same result, as I posted earlier, you will have to manually create a template and include it.
 
Oracle, as I said, that's a feature for v1.3. I posted a video a few pages back, but right now the help page is rather unadvanced an primitive. v1.3 will rectify that.
 
You will need another BB Code with an option and then use that for the column header.
Something like [th=50]Text[/th] - where 50 is the number of pixels.

The html code would be something like:
Code:
<td style="width: {1}px">

That worked perfectly btw. I made my own BB code for the first time using the existing TH and the modification you suggested.
 
ok so I managed to blow up my second attempt at adding a BBCode. I can't figure out where I went wrong so any advice would he helpful.

I created a beautiful looking table using Brogan's Excel model and the BBCode Manager add-on. Everything was great except I wanted to add some additional horizontal padding. So I created a new BBCode [td3] which accepted a value for the padding. I used td2 as a model. I removed text-align: right, and then I replaced the 3px in the padding with {1}px. I saved the new BBCode and checked my Help > BBCode menu. Everything appeared perfect.

BBCode2.webp

So I replaced [td] with [td3=10] in all my code, saved the thread and then....

Fatal error: Maximum execution time of 30 seconds exceeded in /home/terapvpc/public_html/library/XenForo/Template/Abstract.php on line 251

After a bit of troubleshooting I determined I only received the above error when trying to access the particular thread with the new bbcode. I went into table xf_post, copied the message field, removed the new bbcode and updated. The thread then was accessible.

So clearly I made an error in my new BB Code but I cannot see it.

BBCode.webp
 
Don't use advanced options and replace {1} with %s. That may heolp.

that did not work. All of the data in td3 rows appeared as text before the table, instead of appearing within the table. But at least there wasn't an XF error so improvement!

Works! At first I made an error and close with /td instead of /td3. Your suggestion is what resolved the issue.

I thought %s was for text, and {1} for numerical values? I noticed Scrolling Box used a numeric value. I tried to mirror that setup.

Why do the advanced options work for Scrolling Box and TH2? but it gives an error in the manner I was using it?
 
that did not work. All of the data in td3 rows appeared as text before the table, instead of appearing within the table. But at least there wasn't an XF error so improvement!

Works! At first I made an error and close with /td instead of /td3. Your suggestion is what resolved the issue.

I thought %s was for text, and {1} for numerical values? I noticed Scrolling Box used a numeric value. I tried to mirror that setup.

Why do the advanced options work for Scrolling Box and TH2? but it gives an error in the manner I was using it?
I'm not entirely sure. The {1} is for advanced options, meaning more than 1. I've consolidated them in the future.
 
How can I within BB Code increase the font size of data within a table for the entire table?

I tried [table size=] and adding size= along with font-size= within TR but no luck.
 
Use this as the replacement code:
Code:
<table border=0 style="font-size: {1}em">

Make sure Requires Advanced Options is checked.

Use it like this:
Code:
[table=2][tr][td]Test[/td][/tr][/table]
 
Status
Not open for further replies.
Top Bottom