From: <er...@us...> - 2013-02-24 18:51:48
|
Revision: 44957 http://sourceforge.net/p/tikiwiki/code/44957 Author: eromneg Date: 2013-02-24 18:51:43 +0000 (Sun, 24 Feb 2013) Log Message: ----------- [bp 44936] [FIX] 44936 was a partial bp of 44893 to 10.x and creates a minimal fix for html tags being displayed for posts created in the wysiwyg editor (thanks jonny) Modified Paths: -------------- branches/9.x/lib/wiki-plugins/wikiplugin_bloglist.php Modified: branches/9.x/lib/wiki-plugins/wikiplugin_bloglist.php =================================================================== --- branches/9.x/lib/wiki-plugins/wikiplugin_bloglist.php 2013-02-24 02:51:29 UTC (rev 44956) +++ branches/9.x/lib/wiki-plugins/wikiplugin_bloglist.php 2013-02-24 18:51:43 UTC (rev 44957) @@ -125,7 +125,13 @@ $blogItems = $bloglib->list_blog_posts($params['Id'], false, $params['offset'], $params['Items'], $params['sort_mode'], $params['find'], $dateStartTS, $dateEndTS); $temp_max = count($blogItems["data"]); for ($i = 0; $i < $temp_max; $i++) { - $blogItems["data"][$i]["parsed_data"] = $tikilib->parse_data($bloglib->get_page($blogItems["data"][$i]["data"], 1), array('is_html' => ($params['isHtml'] === 'y'))); + // curiously in tiki 10 and before non-wysiwyg posts get parsed in bloblib. This is fixed more completely in tiki 11+ + $is_html = $blogItems['data'][$i]['wysiwyg'] === 'y' && $prefs['wysiwyg_htmltowiki'] !== 'y'; + if ($is_html) { + $blogItems['data'][$i]['parsed_data'] = $tikilib->parse_data($bloglib->get_page($blogItems['data'][$i]['data'], 1), array('is_html' => true)); + } else { + $blogItems['data'][$i]['parsed_data'] = $blogItems['data'][$i]['data']; + } if ($prefs['feature_freetags'] == 'y') { // And get the Tags for the posts global $freetaglib; include_once('lib/freetag/freetaglib.php'); $blogItems["data"][$i]["freetags"] = $freetaglib->get_tags_on_object($blogItems["data"][$i]["postId"], "blog post"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |