Constants

VERSION

VERSION

Properties

$empty_element_suffix

$empty_element_suffix : string

Change to ">" for HTML output.

Type

string

$tab_width

$tab_width : integer

Define the width of a tab for code blocks.

Type

integer

$no_markup

$no_markup : 

Change to `true` to disallow markup or entities.

Type

$no_entities

$no_entities : 

Type

$predef_urls

$predef_urls : 

Predefined urls and titles for reference links and images.

Type

$predef_titles

$predef_titles : 

Type

$list_level

$list_level : 

Type

$in_anchor

$in_anchor : boolean

Status flag to avoid invalid nesting.

Type

boolean

$fn_id_prefix

$fn_id_prefix : 

Type

$fn_link_title

$fn_link_title : 

Type

$fn_backlink_title

$fn_backlink_title : 

Type

$fn_link_class

$fn_link_class : 

Type

$fn_backlink_class

$fn_backlink_class : 

Type

$predef_abbr

$predef_abbr : 

Type

$footnotes

$footnotes : 

Type

$footnotes_ordered

$footnotes_ordered : 

Type

$abbr_desciptions

$abbr_desciptions : 

Type

$abbr_word_re

$abbr_word_re : 

Type

$footnote_counter

$footnote_counter : 

Type

$block_tags_re

$block_tags_re : 

Type

$context_block_tags_re

$context_block_tags_re : 

Type

$contain_span_tags_re

$contain_span_tags_re : 

Type

$clean_tags_re

$clean_tags_re : 

Type

$auto_close_tags_re

$auto_close_tags_re : 

Type

$em_relist

$em_relist : 

Type

$strong_relist

$strong_relist : 

Type

$em_strong_relist

$em_strong_relist : 

Type

$urls

$urls : \Kaloa\Renderer\Markdown\type

Internal hashes used during transformation.

Type

\Kaloa\Renderer\Markdown\type

$titles

$titles : 

Type

Methods

setup()

setup() 

Called before the transformation process starts to setup parser states.

teardown()

teardown() 

Called after the transformation process to clear any variable which may be taking up memory unnecessarly.

transform()

transform(string  $text) : string

Main function. Performs some preprocessing on the input text and pass it through the document gamut.

Parameters

string $text

Returns

string

runBlockGamut()

runBlockGamut(string  $text) : string

Run block gamut tranformations.

These are all the transformations that form block-level tags like paragraphs, headers, and list items.

Parameters

string $text

Returns

string

runSpanGamut()

runSpanGamut(string  $text) : string

Run span gamut tranformations.

These are all the transformations that occur within block-level tags like paragraphs, headers, and list items.

Parameters

string $text

Returns

string

outdent()

outdent(string  $text) : string

Remove one level of line-leading tabs or spaces

Parameters

string $text

Returns

string

MarkdownExtra_Parser()

MarkdownExtra_Parser() 

hashHTMLBlocks()

hashHTMLBlocks(  $text) 

Parameters

$text

_hashHTMLBlocks_inMarkdown()

_hashHTMLBlocks_inMarkdown(  $text,   $indent,   $enclosing_tag_re = '',   $span = false) 

Parameters

$text
$indent
$enclosing_tag_re
$span

_hashHTMLBlocks_inHTML()

_hashHTMLBlocks_inHTML(  $text,   $hash_method,   $md_attr) 

Parameters

$text
$hash_method
$md_attr

hashClean()

hashClean(  $text) 

Parameters

$text

doHeaders()

doHeaders(  $text) 

Parameters

$text

_doHeaders_attr()

_doHeaders_attr(  $attr) 

Parameters

$attr

_doHeaders_callback_setext()

_doHeaders_callback_setext(  $matches) 

Parameters

$matches

_doHeaders_callback_atx()

_doHeaders_callback_atx(  $matches) 

Parameters

$matches

doTables()

doTables(  $text) 

Parameters

$text

_doTable_leadingPipe_callback()

_doTable_leadingPipe_callback(  $matches) 

Parameters

$matches

_doTable_callback()

_doTable_callback(  $matches) 

Parameters

$matches

doDefLists()

doDefLists(  $text) 

Parameters

$text

_doDefLists_callback()

_doDefLists_callback(  $matches) 

Parameters

$matches

processDefListItems()

processDefListItems(  $list_str) 

Parameters

$list_str

_processDefListItems_callback_dt()

_processDefListItems_callback_dt(  $matches) 

Parameters

$matches

_processDefListItems_callback_dd()

_processDefListItems_callback_dd(  $matches) 

Parameters

$matches

doFencedCodeBlocks()

doFencedCodeBlocks(  $text) 

Parameters

$text

_doFencedCodeBlocks_callback()

_doFencedCodeBlocks_callback(  $matches) 

Parameters

$matches

_doFencedCodeBlocks_newlines()

_doFencedCodeBlocks_newlines(  $matches) 

Parameters

$matches

formParagraphs()

formParagraphs(  $text) 

Parameters

$text

stripFootnotes()

stripFootnotes(  $text) 

Parameters

$text

_stripFootnotes_callback()

_stripFootnotes_callback(  $matches) 

Parameters

$matches

doFootnotes()

doFootnotes(  $text) 

Parameters

$text

appendFootnotes()

appendFootnotes(  $text) 

Parameters

$text

_appendFootnotes_callback()

_appendFootnotes_callback(  $matches) 

Parameters

$matches

stripAbbreviations()

stripAbbreviations(  $text) 

Parameters

$text

_stripAbbreviations_callback()

_stripAbbreviations_callback(  $matches) 

Parameters

$matches

doAbbreviations()

doAbbreviations(  $text) 

Parameters

$text

_doAbbreviations_callback()

_doAbbreviations_callback(  $matches) 

Parameters

$matches

runBasicBlockGamut()

runBasicBlockGamut(string  $text) : string

Run block gamut tranformations, without hashing HTML blocks. This is useful when HTML blocks are known to be already hashed, like in the first whole-document pass.

Parameters

string $text

Returns

string