/[drupal]/contributions/modules/marksmarty/marksmarty.module
ViewVC logotype

Diff of /contributions/modules/marksmarty/marksmarty.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.21, Tue Jan 22 22:25:27 2008 UTC revision 1.22, Wed Feb 20 18:07:59 2008 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: marksmarty.module,v 1.20 2008/01/22 21:57:25 weitzman Exp $  // $Id: marksmarty.module,v 1.21 2008/01/22 22:25:27 weitzman Exp $
3    
4  /********************************************************************  /********************************************************************
5   * Drupal Hooks   * Drupal Hooks
# Line 112  function marksmarty_help($path = 'admin/ Line 112  function marksmarty_help($path = 'admin/
112   ********************************************************************/   ********************************************************************/
113    
114  function _marksmarty_process($text, $format) {  function _marksmarty_process($text, $format) {
115    require_once(dirname(__FILE__) .'/markdown.php');    if (!empty($text) && variable_get("marksmarty_is_markdown_on_$format", 1) == 1) {
116    require_once(dirname(__FILE__) .'/smartypants.php');      require_once(dirname(__FILE__) .'/markdown.php');
   if (variable_get("marksmarty_is_markdown_on_$format", 1) == 1) {  
117      $text = Markdown($text);      $text = Markdown($text);
118    }    }
119    if (variable_get("marksmarty_is_smarty_on_$format", 1) == 1) {    if (!empty($text) && variable_get("marksmarty_is_smarty_on_$format", 1) == 1) {
120      global $smartypants_attr;      global $smartypants_attr;
121        require_once(dirname(__FILE__) .'/smartypants.php');
122    
123      $smartypants_attr = variable_get("marksmarty_smarty_hyphens_$format", 0) + 1;      $smartypants_attr = variable_get("marksmarty_smarty_hyphens_$format", 0) + 1;
124      $text = SmartyPants($text);      $text = SmartyPants($text);
125    }    }

Legend:
Removed from v.1.21  
changed lines
  Added in v.1.22

  ViewVC Help
Powered by ViewVC 1.1.2