1 (edited by DiD 2011-08-08 17:39)

Topic: [Release] Extended BBCode version 2

Version 2 of Extended bbcode is released today. I needed a new version for a forum I'm setting up.
This version uses CSS3 if the browser supports it.

List of bbcodes:
Text alignment: center , right , justify
Text related: highlight=#FFFF00 , textsize=3em
Containers: box , note=Firstline , spoiler=CustomTitle
Optional: Admins choice to restyle quote and code

Tested with PunBB 1.3.4 and 1.3.5 on IE8 IE9 , FireFox v3.5 to v5 and Google Chrome.

ATTENTION: Official extension pun_bbcode needs to be installed first.
Find the pun_bbcode extension here:http://punbb.informer.com/extensions/

When installing this extension, you'll be warned to install pun_bbcode before pun_extended_bbcode.
http://www3.picturepush.com/photo/a/6082411/1024/Picture-Box/ext-bbcode-install.png

Installation:

  • If you got an older version installed, uninstall it first. After that delete the entire pun_extended_bbcode folder.

  • Unzip (keep the folder structure intact) into your punbb/extension folder and go to the administration extensions. Find the Extended bbcode section and click on install.

  • When you use a different theme then the default Oxygen, copy the png icons from the pun_bbcode/buttons/Oxygen folder into the pun_extended_bbcode/buttons/Oxygen folder. Then rename the Oxygen folder to the theme name you use.

Version 2.0.1 release

  • Optimized the integration with the official pun_bbcode extension.

  • CSS3 styles are used when the client browser allows it. Supports IE9.

  • Added a new textsize bbcode.

  • Added two options in the admin settings features. These options change the look of the code and quote bbcode.

  • BBcode help page updated.

  • Language files included: English, Dutch, French and German.

So here are some screen shots of the extension in action.

http://www5.picturepush.com/photo/a/6083718/1024/Picture-Box/v2-examples.png

Screenshot of the restyled quote and code bbcode.

http://www5.picturepush.com/photo/a/6083968/1024/Picture-Box/v2-examples2.png

Download Extended bbcode: pun_extended_bbcode_v2.zip

Have fun with it.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

VERY cool. Just tried it and especially like the spoiler!

PS: How do you HIDE again... what code would I need to add?

Question: I'm trying to post 4 divx clips each in a seperate spoiler and then when the user has finished one, he can click hide and show the next one....

3

Re: [Release] Extended BBCode version 2

Thanks KeyDog.  big_smile

I guess adding a second button (hide) that becomes visible after clicking the show button is a possibility.
If you want I can try to add that. Just started to code for PunBB two days ago.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

DiD wrote:

Just started to code for PunBB two days ago.

Good to have you on board.

DiD wrote:

If you want

It would be useful I'm sure having the hide aswell as the show...

5

Re: [Release] Extended BBCode version 2

OK. I'll code the Hide button in it.

I'll make the spoiler a separate extension too, for people who want just that alone.
A little busy this weekend, so it'll be monday before I update the extension.

P.S. I'm trying to do a [youtube] bbcode too, but keep running into trouble with the URL inside the tags.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

Did you see this one:

http://punbb.informer.com/forums/topic/ … otag-v020/

will save you time big_smile like that you can code hide button tongue

7

Re: [Release] Extended BBCode version 2

Oh, thx for the link. Didn't came across it yet.

The button has my priority to code. No worries.  tongue

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

8

Re: [Release] Extended BBCode version 2

Version 1.0.1 released.

See first post for details.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

Excellent stuff.

Btw RE: the 'hide' and 'show' , and also word spoiler...
I needed it for another language forum so I changed it in manifest.xml
but in future one could probably add

<?php echo $lang_help['Show'] ?>
<?php echo $lang_help['Hide'] ?>
<?php echo $lang_help['Spoiler'] ?>

at the relevant place in manifest and add those three to lang/english.php

I think the extension shoud be added here, would unclutter posts if people posted the blocks of code in the spoiler for example...

PS: nice active forum you have over at ndsthemes.com running 1.3.4

10

Re: [Release] Extended BBCode version 2

Mmm, didn't think of the words could be needed in another language. Guess that's why you senior members are around here.  wink  Will fix that too.

It's not my forum, just helping moderate it.  big_smile

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

11

Re: [Release] Extended BBCode version 2

Version 1.0.2 released.

See first post for details.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

Nice, thanks!

Re: [Release] Extended BBCode version 2

Hi - I've found if there is an empty line break in the text it doesn't center, any idea on a fix?

14

Re: [Release] Extended BBCode version 2

Toke me a bit longer to figure this one out.

parser.php seems to convert carriage returns (CR) in an strange way.

CR followed by text is translated into a xhtml break <br />
CR followed by an empty CR is translated in  </p><p>
CR followed by 2 empty CR and then text is translated in </p><br /><p>

And so on...

So the paragraph tags cause that left alignment of the text after the empty line break or carriage return.

I had to experiment a bit and found a solution that doesn't interfere with the rest of the bbcode.
Before parsing, I replace carriage return into %BR%. When done parsing I replace %BR% with the BR tags.

Problem solved.  big_smile

Also included a css style file now. See change log in the first post for details.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

15

Re: [Release] Extended BBCode version 2

Hi,

very nice extension, thanks!


I got one small problem when centering a URL. This is my message:

[center]http://google.com[/center]

After posting this, the link is shown correctly, but when I click on it I get forwarded to

Without centering, everythings works fine.


Can anyone help?
Thanks.

16

Re: [Release] Extended BBCode version 2

Resolved the problem.

Recoded the CENTER bbcode. Now CSS is used to get proper alignment. No more problems with empty new lines and wrong URL's.

Added 2 new bbcodes a long the way, based on the center code, RIGHT and JUSTIFY alignment.

See first post for details and new download link.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

17

Re: [Release] Extended BBCode version 2

Works like a charm, thank you! big_smile

18 (edited by nathbot 2010-03-31 13:59)

Re: [Release] Extended BBCode version 2

Hi,
this really is a great extension, nice job!

Now, sorry to rain on the parade... but I've got one problem and one request.

The problem:
everything seems to work correctly except that I get this message right before all the BB buttons are displayed:

"Notice: Undefined index: path in [my root]/www/forum/extensions/pun_bbcode/bar.php  on line 53
Notice: Undefined index: url in [my root]/www/forum/extensions/pun_bbcode/bar.php on line 56"

I have other extensions installed, I tried deactivating some of them, it didn't change anything.
Any idea of what could cause this?

And the request: a button to change the size of the text (or maybe just two buttons, one for "small" and one for "large", I'm not sure which is best).

I'll keep looking into it on my side, but again, thanks for this great extension.

19

Re: [Release] Extended BBCode version 2

The errors normally occur when you don't have the official pun_bbcode installed.

Check this page for the official pun_bbcode extension:
http://punbb.informer.com/extensions/


As for your request.

[h]This is a header bbcode[/h]

The header bbcode enlarges the text. So I don't see the need for an extra tag.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

Re: [Release] Extended BBCode version 2

I had the correct pun_bbcode extension, but I guess there was something I messed up somewhere else, since it works okay with a clean installation of the forum. I'll try starting from scratch again. Thanks for your answer. smile

DiD wrote:

The header bbcode enlarges the text. So I don't see the need for an extra tag.

My bad, I completely missed that tag in the BBCode help page...

I still could use a "small" tag, but it might not be too complicated to add by myself. wink

21

Re: [Release] Extended BBCode version 2

Great extension!

It works, but the additional bbcode buttons do not appear.

22

Re: [Release] Extended BBCode version 2

You need to have the pun_bbcode extension installed.

Also extraction of the zip file needs to be done with "restore folders" option on.

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

23

Re: [Release] Extended BBCode version 2

DiD wrote:

You need to have the pun_bbcode extension installed.

Also extraction of the zip file needs to be done with "restore folders" option on.

pun_bbcode extension is installed. I've already re-installed it, too!

It's not a problem with the folder structure either. The buttons do not even appear in the HTML source.

No matter whether I'm using Oxygen (default style) or my own style.

$(/var/www/.../extensions) ls -l pun_extended_bbcode/
total 24
drwxr-xr-x 3 root root 4096 2010-04-02 21:17 buttons
drwxr-xr-x 2 root root 4096 2010-04-02 21:13 lang
-rw-r--r-- 1 root root 8622 2010-03-30 13:44 manifest.xml
-rw-r--r-- 1 root root 1230 2010-03-30 11:28 styles.css

24

Re: [Release] Extended BBCode version 2

Very strange. Seems no one else has trouble with the buttons.
I'll try to check it out some more. You're using UNIX?

//== Moderator on www.ndsthemes.com ==\\
\\==   Forum powered there by PunBB     ==//

25

Re: [Release] Extended BBCode version 2

Ubuntu 8.04, Apache 2.2, PHP 5.2.13.

It's also strange since the bbcode help page includes the new bbcodes... So, the plugin is active, but not 100% working.

Installed extensions:

  • Additional BBcode

  • Antispam System

  • BBCode buttons

  • PunBB Repository

  • Pun tags (disabled)

Apache error log does not contain PHP errors related to punbb.