User Tools

Site Tools


processwire:markdown

This is an old revision of the document!


tentative 1

  1. Modules → Refresh
  2. Modules → Install → InputFieldAceEditor
  3. Setup → Fields → add new
  4. Field Setup
    1. basic : textarea
    2. details : html entity encoders (htmlspecialchars), inputfield type : AceEditor, content type : Markup/HTML with image management
front

on dirait qu'il y a par défaut un parser markdown : TextformatterMarkdownExtra

info ici : https://github.com/ryancramerdesign/ProcessWire/tree/master/wire/modules/Textformatter/TextformatterMarkdownExtra/parsedown-extra

<?php
// includes
$markdown_module_path = "../../wire/modules/Textformatter/TextformatterMarkdownExtra/";
require $markdown_module_path."parsedown/Parsedown.php";
require $markdown_module_path."parsedown-extra/ParsedownExtra.php";
// declaring parser
$Extra = new ParsedownExtra();
//use
echo $Extra->text($page->Markdown); ?>
processwire/markdown.1454936178.txt.gz · Last modified: 2016/02/08 13:56 by leo