function FM_TTML_format($blogid, $id, $content, $keywords = array(), $useAbsolutePath = true, $bRssMode = false) { global $service; $path = __TEXTCUBE_ATTACH_DIR__ . "/{$blogid}"; $url = "{$service['path']}/attach/{$blogid}"; $view = FM_TTML_bindAttachments($id, $path, $url, $content, $useAbsolutePath, $bRssMode); // if (is_array($keywords)) $view = FM_TTML_bindKeywords($keywords, $view); $view = FM_TTML_bindTags($id, $view); return $view; }
function FM_TTML_format($blogid, $id, $content, $keywords = array(), $useAbsolutePath = true, $bRssMode = false) { $context = Model_Context::getInstance(); $path = __TEXTCUBE_ATTACH_DIR__ . "/{$blogid}"; $url = $context->getProperty("service.path") . "/attach/{$blogid}"; $view = FM_TTML_bindAttachments($id, $path, $url, $content, $useAbsolutePath, $bRssMode); // if (is_array($keywords)) $view = FM_TTML_bindKeywords($keywords, $view); $view = FM_TTML_bindTags($id, $view); return $view; }
function FM_Markdown_format($blogid, $id, $content, $keywords = array(), $useAbsolutePath = true, $bRssMode = false) { global $service; $path = __TEXTCUBE_ATTACH_DIR__ . "/{$blogid}"; $url = "{$service['path']}/attach/{$blogid}"; if (!function_exists('FM_TTML_bindAttachments')) { // To reduce the amount of loading code! require_once 'ttml.php'; } $view = FM_TTML_bindAttachments($id, $path, $url, $content, $useAbsolutePath, $bRssMode); $view = Markdown($view, $id); $view = FM_TTML_bindTags($id, $view); return $view; }
function FM_Textile_format($blogid, $id, $content, $keywords = array(), $useAbsolutePath = true, $bRssMode = false) { $context = Model_Context::getInstance(); $textile = new Textile(); $path = __TEXTCUBE_ATTACH_DIR__ . "/{$blogid}"; $url = $context->getProperty("service.path") . "/attach/{$blogid}"; if (!function_exists('FM_TTML_bindAttachments')) { // To reduce the amount of loading code! require_once 'ttml.php'; } $view = FM_TTML_bindAttachments($id, $path, $url, $content, $useAbsolutePath, $bRssMode); $view = FM_TTML_preserve_TTML_type_tags($view); $view = $textile->TextileThis($view); $view = FM_TTML_restore_TTML_type_tags($view); $view = FM_TTML_bindTags($id, $view); return $view; }