Well I figured it out...
to fix html problem, open up /tutorials/index.php
find
le="color: #000000"><?php $myts->makeTboxData4Show($myrow['cdesc']);
replace with
le="color: #000000"><?php $cdesc = $myrow['cdesc'];
if you need html in title, then find
le="color: #000000"><?php $myts->makeTboxData4Show($myrow['cname']);
replace with
le="color: #000000"><?php $cname = $myrow['cname'];
Another bug in this module is [ratethis] tag not parsing in tutorial view. To fix it open /tutorials/viewtutorial.php and find
le="color: #000000"><?php $content = str_replace("[date]","$date",$content);
add after
le="color: #000000"><?php $content = str_replace("[ratethis]"," <a href="rate.php?tid=$tid"><b>"._MD_RATETHIS."</b></a>",$content);
There is ton of bugs in this module, it took me last 6 days to fix so it works for me. The blocks are totally screwed up, you will end up re-making them.
Here is my tutorials_top.php file. It should work for you, if you change respective file paths.
<?php /****************************************************************************** * Function: b_tutorials_top_show * Input : $options[0] = date for the most recent links * hits for the most popular tutorials * $block['content'] = The optional above content * $options[1] = How many reviews are displayes * Output : Returns the desired most recent or most popular tutorials ******************************************************************************/ function b_tutorials_top_show($options) { global $xoopsDB, $framebrowse; include_once XOOPS_ROOT_PATH."/modules/anime/cache/config.php"; include XOOPS_ROOT_PATH."/xoops.ccs"; $block = array(); $block['content'] = "<table width='100%' cellpadding="4" cellspacing=0><tr><td id="animenu" cellpadding="3"><small>"; $myts =& MyTextSanitizer::getInstance(); $result = $xoopsDB->query("select tid, tname, tlink, codes, status, hits, date from ".$xoopsDB->prefix("tutorials")." WHERE status=1 or status=3 ORDER BY ".$options[0]." DESC",$options[1],0); while (list($tid, $tname, $tlink, $codes, $status, $hits, $date) = $xoopsDB->fetchRow($result) ) { $tname = $myts->makeTboxData4Show($tname); if ( !XOOPS_USE_MULTIBYTES ){ if (strlen($tname) >= 21) { $tname = substr($tname,0,20)." ..."; } } if ($tlink != "") { if ($framebrowse == 1 || $codes >= 10) { $link_url = "".XOOPS_URL."/modules/anime/viewexttutorial.php?tid=$tid"; $link_target = ""; } else { $link_url = $tlink; $link_target = " target="_blank""; } $block['content'] .= "<a class="menuAni" href="'.$link_url.'" ".$link_target."><strong><big>·</big></strong>".$tname."</a>"; } else { $block['content'] .= "<a href="".XOOPS_URL."/modules/anime/viewtutorial.php?tid=$tid"><strong><big>·</big></strong> $tname</a>"; } $count = 7; //7 days $startdate = (time()-(86400 * $count)); if ($startdate < $time) { if($status==1){ $block['content'] .= " <img src="".XOOPS_URL."/modules/anime/images/newred.gif" />"; } elseif ($status==3){ $block['content'] .= " <img src="".XOOPS_URL."/modules/anime/images/update.gif" />"; } } if($options[0] == "date"){ $block['content'] .= "<div align="right" class="menuMain"> <small>(".formatTimestamp($date,'s').") </small></div>"; $block['title'] = _MB_BLOCK_TITLE1; }elseif($options[0] == "hits"){ $block['content'] .= "<div align="right"> <small>(".$hits.") </small></div>"; $block['title'] = _MB_BLOCK_TITLE2; } } $block['content'] .= "</small></td></tr></table>"; return $block; } function b_tutorials_top_edit($options) { $form = ""._MB_TUTORIALS_DISP." "; $form .= "<input type='hidden' name='options[]' value='"; if($options[0] == "date"){ $form .= "date'"; }else { $form .= "hits'"; } $form .= " />"; $form .= "<input type='text' name='options[]' value='".$options[1]."' /> "._MB_TUTORIALS_TUTS.""; return $form; } ?>
I suggest you modyfy you short timestammp to something good looking, like "05 Apr 08", that way it will look nicer while used with above blocks ^_^
Good luck with this module, if you are going to use it, there is lots more bugs in it.. I found it easier to fix it then to write my own xP