diff -r 6544cc5386ce -r 5dc2963cd75f Symbian.org/Forums.js --- a/Symbian.org/Forums.js Thu Jul 30 16:17:56 2009 +0100 +++ b/Symbian.org/Forums.js Mon Aug 10 11:26:10 2009 +0100 @@ -472,17 +472,35 @@ function convertTag(tag, fulltag, tagContent) { tag = tag.toLowerCase(); + var param = null; + var eqsign = fulltag.indexOf("="); // onclick=\"openURL('" + item.url + "'); + if (eqsign > -1) { + param = fulltag.substring(eqsign+1); + } switch(tag) { + case '*': return bbcode2html(tagContent); case 'b':case 'i':case 'u':case 's':case 'sup':case 'sub':case 'h1':case 'h2':case 'h3':case 'h4':case 'h5':case 'h6':case 'table':case 'tr':case 'th':case 'td': { - return '<' + tag + '>' + tagContent + ""; + return '<' + tag + '>' + bbcode2html(tagContent) + ""; } - case 'quote': return '
' + tagContent + '
'; + case 'font': return '' + bbcode2html(tagContent) + ''; + case 'size': return '' + bbcode2html(tagContent) + ''; + case 'color': return '' + bbcode2html(tagContent) + ''; + case 'left': return '
' + bbcode2html(tagContent) + '
'; + case 'right': return '
' + bbcode2html(tagContent) + '
'; + case 'center': return '
' + bbcode2html(tagContent) + '
'; + case 'list': return tagContent; // todo + case 'php': + case 'code': return '
' + tagContent + '
'; + case 'html':{ + var escaped = tagContent.replace(//g, ">"); + return '
' + escaped + '
'; + } + case 'quote': return '
Quote:
' + tagContent + '
'; case 'url': { - var eqsign = fulltag.indexOf("="); // onclick=\"openURL('" + item.url + "'); if ( eqsign > -1 ) { return "
" + tagContent + '
';