PHPackages                             kokspflanze/sbb-code-parser - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. kokspflanze/sbb-code-parser

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

kokspflanze/sbb-code-parser
===========================

fork from https://github.com/samclarke/SBBCodeParser

0.1.2(9y ago)03.1k1PHPPHP &gt;=5.3

Since Sep 1Pushed 9y ago2 watchersCompare

[ Source](https://github.com/kokspflanze/SBBCodeParser)[ Packagist](https://packagist.org/packages/kokspflanze/sbb-code-parser)[ Docs](https://github.com/kokspflanze/SBBCodeParser)[ RSS](/packages/kokspflanze-sbb-code-parser/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (3)DependenciesVersions (4)Used By (1)

SBBCodeParser v1.1
==================

[](#sbbcodeparser-v11)

Copyright (C) 2011, Sam Clarke ()

SBBCodeParser is a simple BBCode parser.

### Example usage:

[](#example-usage)

```
$parser = new \SBBCodeParser\Node_Container_Document();

$parser->add_emoticons(array(
	':)' => 'http://localhost/Classes/SCEditor-punbb/punbb-1.3.5/img/smilies/smile.png',
	'=)' => 'http://localhost/Classes/SCEditor-punbb/punbb-1.3.5/img/smilies/smile.png'
));

echo $parser->parse('This should be [b]bold[/b] and this should be [i]italic[/i]')
	->detect_links()
	->detect_emails()
	->detect_emoticons()
	->get_html();

```

### Example of adding a custom BBCode:

[](#example-of-adding-a-custom-bbcode)

```
$bbcode = new \SBBCodeParser\BBCode('youtube', function($content, $attribs)
{
    if (preg_match('/http([s]?):\/\/(([w]{3}\.)?)youtube\.com\//s', $content)) {
        $uri = str_replace('http://', 'https://', $content);
    } else {
        $uri = 'https://www.youtube.com/embed/' . $content;
    }

	return '';
}, \SBBCodeParser\BBCode::BLOCK_TAG, false, array(), array('text_node'), \SBBCodeParser\BBCode::AUTO_DETECT_EXCLUDE_ALL);

$parser->add_bbcode($bbcode);

```

### Currently included default BBCodes:

[](#currently-included-default-bbcodes)

```
b
i
strong
em
u
s
blink
sub
sup
ins
del
right
left
center
justify
note
hidden
abbr
acronym
icq
skype
bing
google
wikipedia
youtube
vimeo
flash
paypal
pastebin
gist
twitter
tweets
googlemaps
pdf
scribd
spoiler
tt
pre
code
php
quote
font
size
color
list
ul
ol
li
*
table
th
h
tr
row
r
td
col
c
notag
nobbc
noparse
h1
h2
h3
h4
h5
h6
big
small
br
sp
hr
anchor
goto
jumpto
img
email
url

```

License
=======

[](#license)

SBBCodeParser is licensed under the LGPL license:

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 50% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~174 days

Total

3

Last Release

3601d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1885435?v=4)[Oliver](/maintainers/kokspflanze)[@kokspflanze](https://github.com/kokspflanze)

---

Top Contributors

[![kokspflanze](https://avatars.githubusercontent.com/u/1885435?v=4)](https://github.com/kokspflanze "kokspflanze (10 commits)")[![jmocha](https://avatars.githubusercontent.com/u/8739963?v=4)](https://github.com/jmocha "jmocha (5 commits)")[![christianrank](https://avatars.githubusercontent.com/u/3001431?v=4)](https://github.com/christianrank "christianrank (4 commits)")[![samclarke](https://avatars.githubusercontent.com/u/490870?v=4)](https://github.com/samclarke "samclarke (1 commits)")

---

Tags

SBBCodeParser

### Embed Badge

![Health badge](/badges/kokspflanze-sbb-code-parser/health.svg)

```
[![Health](https://phpackages.com/badges/kokspflanze-sbb-code-parser/health.svg)](https://phpackages.com/packages/kokspflanze-sbb-code-parser)
```

###  Alternatives

[mck89/peast

Peast is PHP library that generates AST for JavaScript code

19037.7M41](/packages/mck89-peast)[karriere/json-decoder

JsonDecoder implementation that allows you to convert your JSON data into PHP class objects

140439.4k12](/packages/karriere-json-decoder)[sauladam/shipment-tracker

Parses tracking information for several carriers, like UPS, USPS, DHL and GLS by simply scraping the data. No need for any kind of API access.

9642.0k](/packages/sauladam-shipment-tracker)[jstewmc/rtf

Read and write Rich Text Format (RTF) documents with PHP

46143.1k6](/packages/jstewmc-rtf)[json-mapper/laravel-package

The JsonMapper package for Laravel

25188.9k3](/packages/json-mapper-laravel-package)[moonshine/layouts-field

Field for repeating groups of fields for MoonShine

107.9k](/packages/moonshine-layouts-field)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
