iPokemon.php Coding Mod
     Head Coder Honorary Admin Pokemon Fanatics Leader[M:200] member is offline
When life gives you lemons, throw them at passerbys.
Joined: Jul 2010 Gender: Male  Posts: 439 Karma: 3 |  | [CB] Style Tags « Thread Started on Jul 8, 2010, 5:20pm » | |
Code:<script type="text/javascript"><!-- /* Style UBBC Tags Created by iPokemon Do not redistribute or call as your own Updated Dec. 23rd, 2010 Copyright 2010 */
if(document.postForm) { document.postForm.color.parentNode.innerHTML+='<a href="javascript:add(\'[style=]\',\'[/style]\')"><img src="http://i52.tinypic.com/66x2m1.png" alt="Style" border="0" /></a>'; }
//Replacement Portion if(pb_action.match(/(calendar|pm|pre)view|search2|display/i)){ var td = document.getElementsByTagName('td'); var matCH=/\[style=(.+?)\](.+?)\[\/style\]/gi; for(l=0;l<td.length;l++){ if(td[l].width=="80%"&&td[l].innerHTML.match(matCH)){ td[l].innerHTML = td[l].innerHTML.replace(matCH, '<div style="$1;">$2</div>'); } } } //--></script> |
|
Placement: Global Footer Instructions: How this works: You put [style=such and such;]Stuff to be styled[/style] This code only knows CSS, so only use CSS styles. http://www.w3schools.com/css/default.asp for more styles
|
|
|