# final class \SmartMarkdownToHTML
{ } ->

Class: SmartMarkdownToHTML - Exports Markdown (v2, smart flavour) Code to HTML Code.

- Language: PHP
- Located at: lib/framework/plugins/lib_markdown.php
- Package: Plugins:ConvertersAndParsers
- Namespace: \
- Class Name: SmartMarkdownToHTML
- Version: v.20241210
- Depends: classes: Smart, SmartEnvironment, SmartUnicode, SmartHtmlParser ; optional-constants: SMART_MARKDOWN_LAZYLOAD_DEFAULT_IMG
- Usage: dynamic object: (new Class())->method() - This class provides only DYNAMIC methods

## class Methods

public function __construct ( bool $y_sBreakEnabled = true, bool $y_mediaExtraEnabled = true, bool $y_lazyLoadImgDisabled = false, string $y_renderOptions = null, string $y_relative_url_prefix = null, bool $y_log_render_notices = false, array $y_arr_preserve_extra_syntax = null, bool $y_useCompatibilityMode = false ) {} @
Class constructor with many options
public function parse ( string $text ) {} -> STRING
@return: {STRING} HTML code
@param: {STRING} $text: The Markdown to be processed
Converts Markdown to HTML

## class Properties

## class Constants

public const ESCAPINGS_REPLACEMENTS = ["\\_" => "_", "\\*" => "*", "\\-" => "-", "\\+" => "+", "\\=" => "=", "\\`" => "`", "\\~" => "~", "\\!" => "!", "\\?" => "?", "\\#" => "#", "\\$" => "$", "\\@" => "@", "\\%" => "%", "\\^" => "^", "\\(" => "(", "\\)" => ")", "\\[" => "[", "\\]" => "]", "\\{" => "{", "\\}" => "}", "\\." => ".", "\\," => ",", "\\:" => ":", "\\;" => ";", "\\<\\<\\<" => "<<<", "\\\\" => "\\"] ; ::

## Sample code: PHP

`

    <?php

    $markdown = new SmartMarkdownToHTML();
     $html = $markdown->parse('Hello **SmartMarkdownToHTML** !');
     // $html would be (default):                 '<div class="mkdw-line">Hello <b>SmartMarkdownToHTML</b> !</div>'
     // or if set with paragraphs $html would be: '<p>Hello <b>SmartMarkdownToHTML</b> !</p>' <!-- paragraphs cannot be nested like divs, but is just another option ... -->

    // #end php code

`

documentation generated on: 2024-12-16 16:53:45 +0000

Smart.Framework © 2009-2024 unix-world.org