mifka01 / bb2md
A class to translate text from BBcode to Markdown.
dev-master
2024-08-21 12:25 UTC
Requires
- php: >=7.4.0
This package is auto-updated.
Last update: 2024-11-21 13:02:20 UTC
README
A class to translate a text from BBCode to Markdown.
The BBCode to Markdown converter is able to convert: bold, italic, underline and strikethrough texts, lists, urls, images, quotes, BB2 images and even code blocks (snippets).
Composer Installation
To install bb2md, you first need to install Composer
bb2md Installation
Once you have installed Composer, it's easy install bb2md.
composer require mifka01/bb2md "dev-master"
- Run the following command in your project root dir:
composer update
Usage
BBCode to Markdown conversion:
use mifka01\bb2md\BBCodeConverter; $converter = new BBCodeConverter(); $convertedText = $converter->toMarkdown($text);
Choose language for img alts:
// available - en (default), cs $converter = new BBCodeConverter('cs');
Requirements
- PHP 7.4.0 or above.
Authors
Filippo F. Fadda - filippo.fadda@programmazione.it - http://www.linkedin.com/in/filippofadda
Radim Mifka - radimmifka@gmail.com
License
bb2md is licensed under the Apache License, Version 2.0 - see the LICENSE file for details.