Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var msg=document.getElementsByName("bbcode");for(var i=0;i<msg.length;i++)
- {
- var txt=document.getElementsByName("bbcode")[i].innerHTML;
- txt=txt.replace(/\[youtube=(.+?)\]/ig,'<div name="video"><embed type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="100%" height="400px" src="$1&vq=large"/></div>');
- txt=txt.replace(/\[PHP\]/ig,'<pre class="quote1">PHP:<hr/><code name="codes" class="code">');
- txt=txt.replace(/\[\/PHP\]/ig, "</code></pre>");
- txt=txt.replace(/\[left\]/ig,'<div align="left">');
- txt=txt.replace(/\[\/left\]/ig, "</div>");
- txt=txt.replace(/\[br\]/ig,'<br/>');
- txt=txt.replace(/\[url=(.+?)\]/ig,'<a href="$1">');
- txt=txt.replace(/\[\/url\]/ig, "</a>");
- txt=txt.replace(/\[link=(.+?)\]/ig,'<a href="$1">');
- txt=txt.replace(/\[\/link\]/ig, "</a>");
- txt=txt.replace(/\[u\]/ig,'<u>');
- txt=txt.replace(/\[\/u\]/ig, "</u>");
- txt=txt.replace(/\[img=(.+?)\]/ig,'<img src="$1" alt="*" title="*"/>');
- //Download
- txt=txt.replace(/\[download\](.+?)\[\/download\]/ig, '<div style="text-align: center;"><span style="background-color: red; font-size: large;">Silahkan Unduh File</span></div><div style="text-align: center;"><b><span style="background-color: #ffd966; font-size: large;"><a href="http://wap4dollar.com/ad/nonadult/serve.php?id=kqepg9ub4i"><span style="color: blue;">Download</span> </a>- <span style="color: red;"><a href="http://$1">Download</a></span></span></b></div></div>');
- txt=txt.replace(/\[b\]/ig,'<b>');
- txt=txt.replace(/\[\/b\]/ig, "</b>");
- txt=txt.replace(/\[s\]/ig,'<s>');
- txt=txt.replace(/\[\/s\]/ig, "</s>");
- txt=txt.replace(/\[center\]/ig,'<center>');
- txt=txt.replace(/\[\/center\]/ig, "</center>");
- txt=txt.replace(/\[right\]/ig,'<div align="right">');
- txt=txt.replace(/\[\/right\]/ig, "</div>");
- txt=txt.replace(/\[justify\]/ig,'<div align="justify">');
- txt=txt.replace(/\[\/justify\]/ig, "</div>");
- txt=txt.replace(/\[input=(.+?)\]/ig,'<span name="codes"><input type="$1" value="');
- txt=txt.replace(/\[\/input\]/ig,'"></input></span>');
- txt=txt.replace(/\[div=(.+?)\]/ig,'<div class="$1">');
- txt=txt.replace(/\[\/div\]/ig,'</div>');
- txt=txt.replace(/\[text\]/ig,'<textarea class="show" rows="3">');
- txt=txt.replace(/\[youtube\](.+?)\[\/youtube\]/ig,'<embed type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="100%" height="400px" src="http://youtube.com/v/$1&vq=large"/>');
- txt=txt.replace(/\[\/text\]/ig, "</textarea>");
- txt=txt.replace(/\[form\]/ig,'<form method="get" action="site_0.xhtml">');
- txt=txt.replace(/\[\/form\]/ig, "</form>");
- txt=txt.replace(/\[option\]/ig, "<option>");
- txt=txt.replace(/\[\/option\]/ig, "</option>");
- txt=txt.replace(/\[select\]/ig, "<select>");
- txt=txt.replace(/\[\/select\]/ig, "</select>");
- txt=txt.replace(/\[indent\]/ig,'<div style="margin-left:12px">');
- txt=txt.replace(/\[\/indent\]/ig, "</div>");
- txt=txt.replace(/\[xt\]/ig,'<span style="display:scroll;position:relative;top:-10px">');
- txt=txt.replace(/\[xb\]/ig,'<span style="display:scroll;position:relative;bottom:-6px">');
- txt=txt.replace(/\[\/x\]/ig, "</span>");
- txt=txt.replace(/\[OL\]/ig,'<div id="mf_content" style="padding:0px 10px 0px"><ol>');
- txt=txt.replace(/\[\/OL\]/ig, "</ol></div>");
- txt=txt.replace(/\[UL\]/ig,'<div id="mf_content" style="padding:0px 10px 0px"><ul>');
- txt=txt.replace(/\[\/UL\]/ig, "</ul></div>");
- txt=txt.replace(/\[LI\]/ig, "<li>");
- txt=txt.replace(/\[\/LI\]/ig, "</li>");
- txt=txt.replace(/\[xp\]/ig,'<div style="padding-top:8px;padding-bottom:8px"><hr style="border-top:1px solid #aaaaaa"/></div>');
- txt=txt.replace(/\[cb\]/ig, '<span class="cb">');
- txt=txt.replace(/\[\/cb\]/ig, '</span>');
- txt=txt.replace(/\[TD\]/ig, '<td class="td" style="padding:2px">');
- txt=txt.replace(/\[\/TD\]/ig, '</td>');
- txt=txt.replace(/\[table\]/ig, '<table width="100%">');
- txt=txt.replace(/\[\/table\]/ig, '</table>');
- txt=txt.replace(/\[TR\]/ig, '<tr>');
- txt=txt.replace(/\[\/TR\]/ig, '</tr>');
- txt=txt.replace(/\[CAPTION\]/ig, '<caption>');
- txt=txt.replace(/\[\/CAPTION\]/ig, '</caption>');
- txt=txt.replace(/\[TD=(.+?)\]/ig,'<td width="$1" class="td" style="padding:2px">');
- txt=txt.replace(/\[FLASH\](.+?)\[\/FLASH\]/ig, '<object width="100%" height="400"><param name="movie" value="$1" /><param name="quality" value="high" /><param name="wmode" value="transparent" /><embed width="100%" height="400" src="$1" quality="high" wmode="transparent" type="application/x-shockwave-flash"></embed></object>');
- txt=txt.replace(/\[MENU\]/ig, '<div class="hidden">');
- txt=txt.replace(/\[\/MENU\]/ig, '</div>');
- txt=txt.replace(/\[penting\]/ig,'<div class="important"><div class="head">Penting:</div><div class="body">');
- txt=txt.replace(/\[\/penting\]/ig,'</div></div>');document.getElementsByName("bbcode")[i].innerHTML=txt;}
Advertisement
Add Comment
Please, Sign In to add comment