Custom BBCode additions

A failed experiment whereby board users were invited to advise the Senate, and instead attempted to replace the Senate.
Locked
User avatar
Uraniun235
Emperor's Hand
Posts: 13772
Joined: 2002-09-12 12:47am
Location: OREGON
Contact:

Custom BBCode additions

Post by Uraniun235 » 2008-12-26 11:53pm

As noted in my signature, and as noted in posts by STARK, strikethrough would be awesome to have.

Fortunately, it appears to be a very simple addition to make, as detailed on this page:
To get started, simply go to your ACP (Administration Control Panel) then click on the Posting tab. Next, click on BBCodes on the left. Since you haven't added any custom ones yet, click on the Add a new BBCode button. You will now see 3 text input areas and a checkbox. The BBCode usage box is where you enter the BBCode -- i.e. similar to what users will enter. The HTML replacement text box is where you enter the HTML replacement code. The Help line text box is where you can enter a tip on how to use your new BBCode. Tips are generally displayed when the user rolls his or her mouse over the BBCode button on the posting screen. Finally the Display on posting page option allows you to show or hide the button on the posting screen. Hiding the button does not disable the BBCode -- users can still manually enter the BBCode.


...


BBCode usage:
{TEXT}


HTML replacement:
<span style="text-decoration: line-through;">{TEXT}</span>


Example usage:
strikethrough text

The page also includes examples for subscript and superscript, which may be handy for when people might like to express exponents without having to go through the hassle of creating/uploading/linking an image, or using the clunky caret character.

I know that our helpful admin staff are quite busy with real-life obligations and with other board management issues, but the impression I get is that this should be a very simple and quick procedure, so hopefully it shouldn't be a burden to implement this should they agree to it.

Thoughts?
"There is no "taboo" on using nuclear weapons." -Julhelm
Image
What is Project Zohar?
"On a serious note (well not really) I did sometimes jump in and rate nBSG episodes a '5' before the episode even aired or I saw it." - RogueIce explaining that episode ratings on SDN tv show threads are bunk

User avatar
Darth Fanboy
DUH! WINNING!
Posts: 11182
Joined: 2002-09-20 05:25am
Location: Mars, where I am a totally bitchin' rockstar.

Re: Custom BBCode additions

Post by Darth Fanboy » 2008-12-27 08:21am

Seconded, the motion passes. *grumbling from moderators* Wait, what do you mean I can't do that here?

I support this idea, especially if it is indeed this simple to implement.
"If it's true that our species is alone in the universe, then I'd have to say that the universe aimed rather low and settled for very little."
-George Carlin (1937-2008)

"Have some of you Americans actually seen Football? Of course there are 0-0 draws but that doesn't make them any less exciting."
-Dr Roberts, with quite possibly the dumbest thing ever said in 10 years of SDNet.

User avatar
CmdrWilkens
Emperor's Hand
Posts: 9093
Joined: 2002-07-06 01:24am
Location: Land of the Crabcake
Contact:

Re: Custom BBCode additions

Post by CmdrWilkens » 2008-12-27 11:35am

If it is that easy I think it would be worthwhile to have. That being said I can see an awful lot more use out of super- and subscript.
Image
SDNet World Nation: Wilkonia
Armourer of the WARWOLVES
ASVS Vet's Association (Class of 2000)
Former C.S. Strowbridge Gold Ego Award Winner
MEMBER of the Anti-PETA Anti-Facist LEAGUE

"I put no stock in religion. By the word religion I have seen the lunacy of fanatics of every denomination be called the will of god. I have seen too much religion in the eyes of too many murderers. Holiness is in right action, and courage on behalf of those who cannot defend themselves, and goodness. "
-Kingdom of Heaven

User avatar
Rogue 9
Scrapping TIEs since 1997
Posts: 18009
Joined: 2003-11-12 01:10pm
Location: Classified
Contact:

Re: Custom BBCode additions

Post by Rogue 9 » 2008-12-27 02:08pm

It's very easy; tables can be done too. I have superscript, subscript, tables, spoiler blocks, and a few other handy BBCodes already encoded in my own board on phpBB3; to make it as easy as possible, I can provide the necessary coding (which is already easy enough, as evidenced by the fact that I managed to implement it myself :razz:), and then all an admin would have to do is copy it to the relevant section of the ACP.
It's Rogue, not Rouge!

HAB | KotL | VRWC/ELC/CDA | TRotR | The Anti-Confederate | Sluggite | Gamer | Blogger | Staff Reporter | Student | Musician

User avatar
Manus Celer Dei
Jedi Master
Posts: 1486
Joined: 2005-01-01 06:30pm
Location: I need you to relax your anus.
Contact:

Re: Custom BBCode additions

Post by Manus Celer Dei » 2008-12-27 06:13pm

Subscript and superscript would be great. I always get headaches trying to read people's mathsy-sciencesy posts when they're full of ^s and []s and so on and suchforth.
Image
"We will build cities in a day!"
"Man would cower at the sight!"
"We will build towers to the heavens!"
"Man was not built for such a height!"
"We will be heroes!"
"We will BUILD heroes!"
[/size][/i]

User avatar
Edi
Dragonlord
Dragonlord
Posts: 12444
Joined: 2002-07-11 12:27am
Location: Helsinki, Finland

Re: Custom BBCode additions

Post by Edi » 2008-12-30 07:05am

Strikethrough, subscript and superscript would be good additions. Don't know if we need anything else nearly as urgently.
Warwolf Urban Combat Specialist

Why is it so goddamned hard to get little assholes like you to admit it when you fuck up? Is it pride? What gives you the right to have any pride?
–Darth Wong to vivftp

GOP message? Why don't they just come out of the closet: FASCISTS R' US –Patrick Degan

The GOP has a problem with anyone coming out of the closet. –18-till-I-die

User avatar
Eleas
Jaina Dax
Posts: 4893
Joined: 2002-07-08 05:08am
Location: Malmö, Sweden
Contact:

Re: Custom BBCode additions

Post by Eleas » 2008-12-30 11:30am

Edi wrote:Strikethrough, subscript and superscript would be good additions. Don't know if we need anything else nearly as urgently.
I concur. Also, I think a gradual introduction of such changes would aid in debugging, should errors crop up.
"Travelers with closed minds can tell us little except about themselves."
--Chinua Achebe

User avatar
Brother-Captain Gaius
Emperor's Hand
Posts: 6859
Joined: 2002-10-22 12:00am
Location: \m/

Re: Custom BBCode additions

Post by Brother-Captain Gaius » 2009-01-08 05:20am

This would be an excellent addition. The applications and usefulness of superscript and subscript are obvious, particularly to such a science-oriented board such as this.

Strikethrough, though admittedly more for comedic purposes, is a versatile and generally handy thing to have. It belongs right alongside bold, italic, and underline.
Agitated asshole | (Ex)40K Nut | Metalhead
The vision never dies; life's a never-ending wheel
1337 posts as of 16:34 GMT-7 June 2nd, 2003

"'He or she' is an agenderphobic microaggression, Sharon. You are a bigot." ― Randy Marsh

User avatar
Stark
Emperor's Hand
Posts: 36169
Joined: 2002-07-03 09:56pm
Location: Brisbane, Australia
Contact:

Re: Custom BBCode additions

Post by Stark » 2009-01-08 05:39am

I'm curious about the practicalities of implementing this - I have no idea who has the access to do so any how often they're available.

User avatar
Rogue 9
Scrapping TIEs since 1997
Posts: 18009
Joined: 2003-11-12 01:10pm
Location: Classified
Contact:

Re: Custom BBCode additions

Post by Rogue 9 » 2009-01-08 08:37pm

Implementing them is ludicrously easy, and I can't see how it would cause bugs with the board. The only limitation I'm aware of is whether the admins want to do it and whether or not one of them has five minutes to spare.

Edit: Just to make this simple, a fellow board member asked me for the code for the requested additions (as well as some others that I've implemented on my board) back in October when this first came up. Just to make this easy, I will simply quote my reply. The code next to the lines marked "bbCode:" goes in the field marked bbCode in the custom board codes tab of the ACP, and the code marked HTML goes in the HTML Replacement field just below it.
Rogue 9 wrote:Strikethrough:
bbCode: {TEXT}
HTML: <del>{TEXT}</del>

Spoiler block:
bbCode: Spoiler
{TEXT}
HTML: <span class="spoiler"><span class="spoiler-box" onclick="spoilerToggle(this);"><span class="spoiler-content" style="visibility:hidden;">{TEXT}</span></span></span>

Titled spoiler block:
bbCode: Spoiler
{TEXT2}
HTML: <div class="spoiler"><div class="spoiler-title">{L_PRIME_BBCODE_SPOILER}: <a href="#toggle_spoiler" class="spoiler-link" onclick="return(spoilerToggle(this));">{L_PRIME_BBCODE_SPOILER_SHOW}</a> {TEXT1}</div><div class="spoiler-box" onclick="spoilerToggle(this);"><div class="spoiler-content" style="visibility:hidden;">{TEXT2}</div></div></div>

Subscript:
bbCode: {TEXT}
HTML: <sub>{TEXT}</sub>

Superscript:
bbCode: [sup]{TEXT}[/sup]
HTML: <sup>{TEXT}</sup>

HTML tables are complex, and require multiple tags to work properly. Hence, bbCode tables are similar. The vBulletin board software has a much easier table code, but I haven't yet been able to replicate it, and can't dismantle it to find out how they do it since vBulletin is pay-only and proprietary. At any rate, here are the table codes.

Table tag:
bbCode: [table]{TEXT}[/table]
HTML: <table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" style="border-collapse: collapse">{TEXT}</table>

Table header, used in the top table row to make headers for the columns:
bbCode: [th]{TEXT}[/th]
HTML: <th>{TEXT}</th>

Table row, used to define the beginning and end of a row in a table. Simply using the Return key in the code will not suffice to create a new row; it will simply put a second row of text in the same cell.
bbCode: [tr]{TEXT}[/tr]
HTML: <tr> {TEXT}</tr>

Table cell, used to define cells in the table:
bbCode: [td]{TEXT}[/td]
HTML: <td width="50" valign="top" style="width: 37.5pt; padding-left: 5.4pt; padding-right: 5.4pt; padding-top: 0in; padding-bottom: 0in">
{TEXT}</td>

Table cells of a different background color, in case you want to make rows or columns different colors to help with following them:
bbCode: [td2]{TEXT}[/td2]
HTML: <td width="50" valign="top" style="width: 37.5pt; padding-left: 5.4pt; padding-right: 5.4pt; padding-top: 0in; padding-bottom: 0in; background: #99CCFF">{TEXT}</td>

If you want a different color for the color ones, simply replace the color code (the #99CCFF line in the HTML) with the appropriate color code. If you want to find a color code, simply use the Font Color function on this board, since it uses the color codes instead of text descriptors to denote them. Click the color you want on the palette to the right of the post form and copy that color code into the HTML. If you want more than two colors, of course, you can simply create td3, td4, and so on as additional tags.

When making a table, put all the text on one line. If you use line breaks at every row, the board won't know how to interpret it, since the [tr] tags also include line breaks themselves, and will deal with it by creating a large blank space above the table, with size corresponding to the number of line breaks in the code.

Since making a table this way is a pain in the ass, allow me to direct you to the simple spreadsheet converter. Simply do your table in a spreadsheet, copy it, and paste it into the converter, telling it to convert to HTML. Once that's done, put the result in a word processor, and do a find/replace to replace all < tags with [ and all > tags with ]. There's your bbCode table; post the result and you're done. Much easier than typing it all up.

And that's all the ones I've coded so far. If you want more, it'd be easier to look up an HTML tutorial than to ask me to program them, since I'd have to get a tutorial myself to do it.
Edit2: I see titled spoiler blocks are already in.
It's Rogue, not Rouge!

HAB | KotL | VRWC/ELC/CDA | TRotR | The Anti-Confederate | Sluggite | Gamer | Blogger | Staff Reporter | Student | Musician

User avatar
Imperial Overlord
Emperor's Hand
Posts: 11978
Joined: 2004-08-19 04:30am
Location: The Tower at Charm
Contact:

Re: Custom BBCode additions

Post by Imperial Overlord » 2009-01-12 06:53pm

I'm in favor of it.
The Excellent Prismatic Spray. For when you absolutely, positively must kill a motherfucker. Accept no substitutions. Contact a magician of the later Aeons for details. Some conditions may apply.

rhoenix
Jedi Council Member
Posts: 1910
Joined: 2006-04-22 07:52pm

Re: Custom BBCode additions

Post by rhoenix » 2009-01-21 04:23am

I say the three additions, which are the addition of strikethrough text, as well as subscript and superscript for notation would all be harmless at worst, and useful at best. I'm in favor.

User avatar
Mayabird
Storytime!
Posts: 5970
Joined: 2003-11-26 04:31pm
Location: IA > GA
Contact:

Re: Custom BBCode additions

Post by Mayabird » 2009-01-21 09:24pm

I motion that we take this to a poll and get some strikethrough action started, with subscript and superscripts too. Or, however this "start a poll" stuff works.
DPDarkPrimus is my boyfriend!

SDNW4 Nation: The Refuge And, on Nova Terra, Al-Stan the Totally and Completely Honest and Legitimate Weapons Dealer and Used Starship Salesman slept on a bed made of money, with a blaster under his pillow and his sombrero pulled over his face. This is to say, he slept very well indeed.

User avatar
Uraniun235
Emperor's Hand
Posts: 13772
Joined: 2002-09-12 12:47am
Location: OREGON
Contact:

Re: Custom BBCode additions

Post by Uraniun235 » 2009-01-22 07:54pm

I second the motion.
"There is no "taboo" on using nuclear weapons." -Julhelm
Image
What is Project Zohar?
"On a serious note (well not really) I did sometimes jump in and rate nBSG episodes a '5' before the episode even aired or I saw it." - RogueIce explaining that episode ratings on SDN tv show threads are bunk

User avatar
Count Chocula
Jedi Council Member
Posts: 1821
Joined: 2008-08-19 01:34pm
Location: You've asked me for my sacrifice, and I am winter born

Re: Custom BBCode additions

Post by Count Chocula » 2009-01-22 07:59pm

Edi wrote:Strikethrough, subscript and superscript would be good additions.
If those were added, I'd be hyped enough to click the PayPal icon and give Mike a little love! I'm tired of typing (TM).
Image
The only people who were safe were the legion; after one of their AT-ATs got painted dayglo pink with scarlet go faster stripes, they identified the perpetrators and exacted revenge. - Eleventh Century Remnant

Lord Monckton is my heeerrooo

"Yeah, well, fuck them. I never said I liked the Moros." - Shroom Man 777

User avatar
Havok
Miscreant
Posts: 13016
Joined: 2005-07-02 10:41pm
Location: Oakland CA
Contact:

Re: Custom BBCode additions

Post by Havok » 2009-01-22 08:31pm

Count Chocula wrote:
Edi wrote:Strikethrough, subscript and superscript would be good additions.
If those were added, I'd be hyped enough to click the PayPal icon and give Mike a little love! I'm tired of typing (TM).
This should be done regardless.
Image
It's 106 miles to Chicago, we got a full tank of gas, half a pack of cigarettes, it's dark... and we're wearing sunglasses.
Hit it.
Blank Yellow (NSFW)
"Mostly Harmless Nutcase"

User avatar
Phantasee
Was mich nicht umbringt, macht mich stärker.
Posts: 5776
Joined: 2004-02-26 09:44pm

Re: Custom BBCode additions

Post by Phantasee » 2009-01-23 02:06am

fuck you guys, i'm starting a vote thread!

http://bbs.stardestroyer.net/viewtopic. ... 0&t=130845

Simple enough, Yes/No/Abstain. I figured there's been enough discussion, not just in this thread, but across the board, to warrant a vote thread.

I left out the Tables business because it's horribly ugly, I don't want to scare off the admins, and I don't think there's as much support for that as there is for the three key additions of Strikethrough, Superscript, and Subscript. I mean, I could start a poll to find out...but I'd rather not. :P
XXXI

User avatar
Rogue 9
Scrapping TIEs since 1997
Posts: 18009
Joined: 2003-11-12 01:10pm
Location: Classified
Contact:

Re: Custom BBCode additions

Post by Rogue 9 » 2009-01-23 01:45pm

Fair enough. If someone wants to make a table about something, a subpage on the Imperial Wiki will do just fine; the spreadsheet converter I linked to will also convert to wiki code. An example.
It's Rogue, not Rouge!

HAB | KotL | VRWC/ELC/CDA | TRotR | The Anti-Confederate | Sluggite | Gamer | Blogger | Staff Reporter | Student | Musician

Locked