Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

My new text markup langage

Name: Anonymous 2009-10-01 12:11

It's better than BBCode:
`b`i`o`u{I AM AN EXPERT PROGRAMMER}
`sup{NO `sup{MORE `sup{NESTING `sub{PROBLEMS`b`i{!!}}}}}


Also, the parser in Haskell is 30 lines.

Name: Anonymous 2009-10-06 10:26

>>50

ROCKSTAR PHUBY EDITION!

class BbCode
{
    private function tag($name, $contents)
    {
        return sprintf('<%s>%s</%s>', $name, $contents, $name);
    }   

    public function __call($method, $args)
    {
          $content = isset($args[0]) ? $args[0] : '';
          return $this->tag($method, $contents);
    }
}

$b = new BbCode();
echo $b->b($b->u($b->o($b->sup('D').'S'.$b->sub('L'))));

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List