corzblog bbcode parser preview



Here it is! My [search engine fodder] bbcode to html parser, and html to bbcode parser [/search engine fodder]!

This is the actual very onsite parser that parses the bbcode of my blogs and site comments, which as well its usual tasks of, well, you know, the parsing stuff, also moonlights doing a cute wee background demo of itself, you're looking at it. it knew you wanted to do that. hit the "preview" button to see at least one half of the parser's bbcode to html/html to bbcode functionality.

The front-end (below) is built-in to the parser, you just call the function and it creates the form. The cool, super-portable JavaScript bbcode buttons and functions come in the package, too. Have fun. Oh, and by the way, output is 100% pure HTML5, or nice plain bbcode, which ever way you look at it, it's free.

button to undo the last javascript change
cbparser quick bbcode guide..
Most common bbtags are supported, and with cbparser's InfiniTags™ you can pretty much just make up tags as you go along. If cbparser can construct valid html tags out of them, it will. Experimentation is the key, and preview often.

A few bbcode examples..
[b]bold[/b], [i]italic[/i], [big]big[/big], [sm]small[/sm], [img]http://foo.com/image.png[/img], [code]code[/code],[code]teletype[/code], [url="http://foo.com" title="foo!"]foo U![/url], and more.. To post code with indentation and/or strange characters, .htaccess, etc., use [pre][/pre] tags.
download cbparser
an HTML5 compliant bbcode parser



Welcome to the comments facility!


previous comments (nine pages)   show all comments

cor - 19.05.05 6:54 am

that's what the pre tags are for! smiley for :lol:

;o)
(or


fajarferdian - 20.05.05 12:40 am

Hi, wow.. thanks for the major upgrade ;) well done for you..
And yes.. I think more people will find the phpbb id removal code usefull!..

Adam and Mike, the parses DO let you post codes within ur comments using the pre tags cor mentioned above..for example
like this
[pre]
While (stristr($post_text,'[img:') !== FALSE){
      //do this do that
}
[ /pre]

but then remove the spaces in /pre tag so that it look like this [/pre]

once again, thank you (or smiley for :cool:


mike - 20.05.05 10:55 am

Doh!


Romi Lizada - 20.05.05 10:58 am

Your blog gets nice. Keep up the good work!!!


cor - 21.05.05 7:26 am

Yes, you can use the "pre" tag (pre-formatted text)...
<?php
// and dem pesky spammers..
foreach ($spammer_strings as $key => $value) {
    if(stristr($bb2html, $value)) {
        $bb2html = 'spammer';
    } // zero tolerance!
}
?> 
and if you download the latest beta, you can also use the "ccc" tag (cool colored code) for php examples..

<?php
// and dem pesky spammers..
foreach ($spammer_strings as $key => $value) {
    if(
stristr($bb2html$value)) {
        
$bb2html = 'spammer';
    } // zero tolerance!
}
?>


Which is quite nice, but isn't yet as colorful as I expected, I'll be looking into that (it may just be a css thing).

note, you need to include the <?php ?> tags if you want the syntax highlighting to work.

thanks Romi!
have fun dudes!

;o)
(or


cor - 21.05.05 7:47 am

actually, on posting that, I'm thinking we should just return right there..

<?php
    
// and dem pesky spammers..
    
foreach ($spammer_strings as $key => $value) {
        if(
stristr($bb2html$value)) {
            return 
'spammer';
        } 
// zero tolerance!
    
}
?>


yeah, that's better!

;o)
(or

ps.. fixed the colours! (v7.2b3)


cute - 01.06.05 12:00 am

oh how i feel....!



cute - 01.06.05 12:01 am

shame the newest aren't shown at the top smiley for :ken:


cor - 01.06.05 12:29 pm

Well cute, it has been tried.
It works fine for blogs, but not so good for comments.

;o)
(or


test - 10.07.05 2:14 pm

test


satanuke - 04.08.05 12:38 am


writeln('smiley for :D');



next comments (11 pages)

First, confirm that you are human by entering the code you see..

(if you find the code difficult to decipher, click it for a new one!)


gd verification image

 

Welcome to corz.org!

I'm always messing around with the back-end.. See a bug? Wait a minute and try again. Still see a bug? Mail Me!