Markdown

The Jetpack by WordPress.com Markdown function.

Description

Markdown( $text ); 

Parameters (1)

0. $text
The text.

Usage

  1. if ( !function_exists( 'Markdown' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'jetpack-by-wordpress-com/_inc/lib/markdown/extra.php'; 
  3.  
  4. // The text. 
  5. $text = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = Markdown($text); 
  9.  

Defined (1)

The function is defined in the following location(s).

/_inc/lib/markdown/extra.php  
  1. function Markdown($text) { 
  2. # Initialize the parser and return the result of its transform method. 
  3. # Setup static parser variable. 
  4. static $parser; 
  5. if (!isset($parser)) { 
  6. $parser_class = MARKDOWN_PARSER_CLASS
  7. $parser = new $parser_class; 
  8.  
  9. # Transform text using parser. 
  10. return $parser->transform($text);