<?php
/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */


/**
 * Smarty mbtruncate modifier plugin
 *
 * Type:     modifier<br>
 * Name:     csvescape<br>
 * Purpose:  csv escape
 * @author   Yuki Yoshioka
 * @param string
 * @return string
 */
function smarty_modifier_csvescape($string)
{
    $string = str_replace("\"","\"\"",$string);
            return "\"".$string."\"";
}

?>
