{"id":22783833,"url":"https://github.com/greg-kennedy/php-bbcode","last_synced_at":"2026-02-27T10:40:56.639Z","repository":{"id":50879040,"uuid":"165447841","full_name":"greg-kennedy/php-bbcode","owner":"greg-kennedy","description":"BBCode to HTML conversion, in PHP.","archived":false,"fork":false,"pushed_at":"2021-11-06T06:45:22.000Z","size":30,"stargazers_count":3,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T11:12:47.520Z","etag":null,"topics":["bbcode","html","parser","php"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/greg-kennedy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-12T23:48:33.000Z","updated_at":"2023-04-01T15:27:46.000Z","dependencies_parsed_at":"2022-08-28T03:20:50.943Z","dependency_job_id":null,"html_url":"https://github.com/greg-kennedy/php-bbcode","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/greg-kennedy/php-bbcode","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/greg-kennedy%2Fphp-bbcode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/greg-kennedy%2Fphp-bbcode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/greg-kennedy%2Fphp-bbcode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/greg-kennedy%2Fphp-bbcode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/greg-kennedy","download_url":"https://codeload.github.com/greg-kennedy/php-bbcode/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/greg-kennedy%2Fphp-bbcode/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29892055,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T09:48:51.284Z","status":"ssl_error","status_checked_at":"2026-02-27T09:48:43.992Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bbcode","html","parser","php"],"created_at":"2024-12-11T22:09:34.594Z","updated_at":"2026-02-27T10:40:56.601Z","avatar_url":"https://github.com/greg-kennedy.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# php-bbcode\nBBCode to HTML conversion, in PHP7.\n\n## What is it?\nThis is a PHP include that can convert BBCode into safe HTML output.\n\nFeatures:\n* UTF-8 aware\n* Replaces unsafe HTML characters (`\u003c`, `\u003e`, `\u0026`, ` `) with safe HTML entities (`\u0026lt;`, `\u0026gt;`, `\u0026amp;`, `\u0026nbsp;`)\n* Properly handles various bad input conditions, to ensure correcly closed tags and avoid malformed HTML\n* Public-domain (The Unlicense), just copy-paste into your own projects!\n\n## What does it support?\nThese BBCode tags are supported and converted to HTML equivalent:\n\n* `[b]`, `[i]`, `[u]`, `[s]`, `[sub]`, `[sup]`\n* `[color=X]`, `[size=Y]`, `[font color=X size=Y]`\n* `[quote]` / `[blockquote]`\n* `[pre]` / `[code]`\n* `[ol]`, `[ul]`, `[li]` / `[*]`\n* `[table]`, `[tr]`, `[th]`, `[td]`\n* `[img]http://www.example.com/image.jpg[/img]`\n* `[url]http://www.example.com[/url]` / `[url=http://www.example.com]Example URL[/url]`\n\nIn addition, unsafe HTML characters are converted to safe HTML entities.  Newlines are collapsed and translated as follows:\n\n* `\\r` characters are stripped\n* Single `\\n`: converted to `\\n\u003cbr\u003e`\n* Two or more sequential `\\n`: converted to `\\n\\n\u003cp\u003e`\n\nThe resulting string is whitespace trimmed at beginning and end.\n\n## Notes\nThe common use case `[quote author=X]` is deliberately excluded, because formatting the result for presentation is implementation-dependent.\n\n## Distribution\nbbcode.php is the include file.  Place it in the folder of your choice and then `include_once 'bbcode.php'`;\n\ntest.php is a unit test file.  You do not need this when deploying.\n\n## Contact\nOpen an issue if you find a bug.  Send a pull request if you want to extend it.  I especially like more unit tests, better attempts at catching malformed tags, performance and optimization features.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgreg-kennedy%2Fphp-bbcode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgreg-kennedy%2Fphp-bbcode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgreg-kennedy%2Fphp-bbcode/lists"}