2017 © Pedro Peláez
 

yii2-extension yii2-kartik-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

image

skeeks/yii2-kartik-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  • Wednesday, July 1, 2015
  • by skeeks-semenov
  • Repository
  • 1 Watchers
  • 0 Stars
  • 344 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 8 Versions
  • 0 % Grown

The README.md

yii2-markdown

Latest Stable Version License Total Downloads Monthly Downloads Daily Downloads, (*1)

This module provides Markdown Editing and Conversion utilities for Yii Framework 2.0. It implements markdown conversion using PHP Markdown Extra and PHP Smarty Pants. In addition, you can customize the flavor of Markdown, by including additional custom conversion patterns. The module also includes an enhanced customized Markdown Editor Widget for markdown editing and preview at runtime. This widget is styled using Bootstrap 3.0. View a complete demo., (*2)

Markdown

VIEW DEMO
This is a markdown converter class that uses PHP Markdown Extra and PHP SmartyPantsTypographer for processing Markdown conversion to HTML. It also supports configurable custom conversion processing of patterns for styling your own flavour of Markdown to some extent. View examples and details or view a complete demo., (*3)

MarkdownEditor

VIEW DEMO
This is an advanced markdown input widget with configurable options. It is styled using Bootstrap 3.0. Key features available with this widget are:, (*4)

  1. Configurable toolbar and buttons for formatting content
  2. Live preview of Markdown formatted text as HTML
  3. Maximize editor for full screen editing
  4. Implements PHP Markdown Extra and PHP SmartyPantsTypographer functionality as provided by the Markdown.
  5. Uses Bootstrap 3.0 styling wherever possible
  6. Allows saving/exporting of the text-editor contents as Text or HTML
  7. Configurable header, footer, and input options.
  8. Supports localization and customization of messages and content.

View examples and details or view a complete demo., (*5)

Demo

You can see a demonstration here on usage of these functions with documentation and examples., (*6)

Installation

The preferred way to install this extension is through composer., (*7)

Note: Check the composer.json for this extension's requirements and dependencies. Read this web tip /wiki on setting the minimum-stability settings for your application's composer.json., (*8)

Either run, (*9)

$ php composer.phar require kartik-v/yii2-markdown "dev-master"

or add, (*10)

"kartik-v/yii2-markdown": "dev-master"

to the require section of your composer.json file., (*11)

Usage

Setup Module

Add markdown to your modules section of your Yii configuration file, (*12)

'modules' = [
    /* other modules */
    'markdown' => [
        'class' => 'kartik\markdown\Module',
    ]
];

You can setup additional configuration options for the markdown module:, (*13)

'modules' = [
    'markdown' => [
        // the module class
        'class' => 'kartik\markdown\Module',

        // the controller action route used for markdown editor preview
        'previewAction' => '/markdown/parse/preview',

        // the list of custom conversion patterns for post processing
        'customConversion' => [
            '<table>' => '<table class="table table-bordered table-striped">'
        ],

        // whether to use PHP SmartyPantsTypographer to process Markdown output
        'smartyPants' => true
    ]
    /* other modules */
];

Markdown

use kartik\markdown\Markdown;

// default call
echo Markdown::convert($content);

// with custom post processing
echo Markdown::convert($content, ['custom' => [
    '

<

h1>' => '

<

h1 class="custom-h1>',
    '

<

h2>' => '

<

h1 class="custom-h2>',
]]);

MarkdownEditor

// add this in your view
use kartik\markdown\MarkdownEditor;

// usage with model
echo MarkdownEditor::widget([
    'model' => $model, 
    'attribute' => 'markdown',
]);

// usage without model
echo MarkdownEditor::widget([
    'name' => 'markdown', 
    'value' => $value,
]);

License

yii2-markdown is released under the BSD 3-Clause License. See the bundled LICENSE.md for details., (*14)

The Versions

01/07 2015

dev-master

9999999-dev https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

01/07 2015

v1.3.1

1.3.1.0 https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

12/01 2015

v1.3.0

1.3.0.0 https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

16/12 2014

v1.2.0

1.2.0.0 https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

09/11 2014

1.1.0.x-dev

1.1.0.9999999-dev https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

09/11 2014

v1.1.0

1.1.0.0 https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

05/10 2014

1.0.0.x-dev

1.0.0.9999999-dev https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input

05/10 2014

v1.0.0

1.0.0.0 https://github.com/kartik-v/yii2-markdown

Advanced Markdown editing and conversion utilities for Yii Framework 2.0

  Sources   Download

BSD 3-Clause

The Requires

 

extension yii2 jquery form bootstrap yii editor markdown converter input