SuperBlob Posted August 4, 2009 Posted August 4, 2009 (I still haven't bought my license yet, but this is a suggestion I thought was worth making beforehand.) On my current, free message board software, there exists a BBCode for making inline Tables. The table title line draws its style from the category header CSS, the line that holds the titles for the individual columns draws its style from the 'Forums/Stats/Last Post Info' line from the forum listings, and the individual table cells draws its style from the forum listing itself, or even just from the regular post box. While I'm not saying you couldn't add a way to format the different column widths, the BBCode on the software I use adjusts the width of each column to fit accordingly with the other columns. For example, if there's one column where each row only has one letter, and another one where each row has a full sentence, it automatically shifts the majority of the width of the table over to the latter column to accommodate. So, for example, the basic code for a table might look like this: So, in the above table, the table would automatically shift to the next row after 'Color' and 'Pink', because you specified that each row has only 3 cells in the original code, and it detects that you've added in 3 cells since the last linebreak. I know for a fact that it can be done, because I've seen it done, it's just a matter of effort versus profit, I suppose. And you could even expand on it if you wanted to, by adding the option to custom skin tables on-the-spot if you wanted to, or something like that. It doesn't really matter to me, but I know other people might ask that, so throwing that in there now. Anyway, I know that it's too big of a feature to add in any release of 3.0.x, but maybe something to think about for 3.1?[table=# OF COLUMNS,TABLE TITLE]CELL 1 [c]CELL 2[c]CELL 3...[/table][/CODE] In the above example, [c] represents New Cell, which ends the previous cell and starts the next one. By way of the '# of Columns' field, the BBCode can automatically shift info to the next line without you having to put any other type of tag except for [c] to separate cells. So, for example, the code for a table with 3 rows (including a category header row) and 3 columns about cabbage might look like this: [CODE][table=3,Cabbage]Flavor[c]Place of Origin[c]Color[c]Chocolate[c]Argentina[c]Pink[c]Strawberry[c]Texas[c]Brown[/table]
bfarber Posted August 4, 2009 Posted August 4, 2009 You could this with the custom bbcode system already.
SuperBlob Posted August 4, 2009 Author Posted August 4, 2009 I realize this, but you can do that with a lot of the BBCodes you have pre-installed. I was talking about making it a standard BBCode. And plus, if it was developed by IPB and not as an add-on, it could potentially be a lot more useful and advanced.
Wolfie Posted August 4, 2009 Posted August 4, 2009 I see this as having a lot of potential problems. Don't get me wrong, I see benefits too, but the problems with trying to implement such a feature would be difficult, with trying to overcome potential risks to it messing up the appearance of the page being displayed.
SuperBlob Posted August 4, 2009 Author Posted August 4, 2009 How would it mess up the appearance? Not trying to be rude, just want examples so I can argue back is all.
Michael Posted August 4, 2009 Posted August 4, 2009 [quote name='SuperBlob' date='03 August 2009 - 09:08 PM' timestamp='1249348100' post='1837821'] I realize this, but you can do that with a lot of the BBCodes you have pre-installed. I was talking about making it a standard BBCode. And plus, if it was developed by IPB and not as an add-on, it could potentially be a lot more useful and advanced. Technically, all bbcodes in IPB are now custom bbcodes. I can't see this being that useful to enough boards to actually make it part of the base product, it's best suited to be a mod.
bfarber Posted August 4, 2009 Posted August 4, 2009 1) The internet is moving away from tables to format data. It's fine for tabular data, but that's not what most people tend to use it for (they use it for formatting). We wouldn't want to promote that, if you ask me. Though it's not a good enough reason to not include it really. ;) 2) I can see some user forgetting a closing tag, or adding an opening cell but no opening row (e.g. <table><td> without the <tr>). There's a lot of factors when you deal with so many users - I'm sure you understand how a table works, but the average user on a hobby site might not, and they'd find a way to break it. 3) There has to be a limit to what bbcodes we ship with. We can't include every bbcode (and for sure, this isn't the first request we've had to include a specific custom bbcode by default).
SuperBlob Posted August 4, 2009 Author Posted August 4, 2009 Alright, those are fair reasons. If I need it, I'll add it in myself. Thanks for taking the time to respond anyway!
bfarber Posted August 4, 2009 Posted August 4, 2009 No problem. On a realistic note, it would be easy enough to add through the custom bbcode manager. I'm sure if no one has already made one, you could ask in the peer to peer forums and someone can show you an example how to do it. :)
Wolfie Posted August 4, 2009 Posted August 4, 2009 Set up a custom bbcode and try this as the replacement: <table cellspacing='0' cellpadding='0'><tr> <td>{option}</td> <td>{content}</td> </tr></table> This will let you use (as an example): [table=[b]Hello there!]How are you?[/table] That will give you a left/right 1 row table. You can use whatever bbCode name you want though.
Zone Plate Posted August 7, 2009 Posted August 7, 2009 but what happened to "preformatted" code? I can't find bbcode for a table of stats that I want to cut and paste and have the columns line up.
bfarber Posted August 7, 2009 Posted August 7, 2009 You could easily create a custom bbcode that wrapped the submitted content in <pre></pre> tags. :) That is exactly what pre HTML tags are designed for (pre-formatted).
Recommended Posts
Archived
This topic is now archived and is closed to further replies.