|
| |
|
|
Rocket Boy
Posts: 409 Joined: 12/8/2005 Status: offline
|
Google UBB Tags - 1/31/2006 11:56:19
This is handy for anybody that runs a forum and can probably be modified to work with anything (Copyright intact)... Insert a word or phrase in between these tags and your word or phrase will become a clickable link to a goole search about that word or phrase. [google] FronPageWebmaster.com [/google] Obviously... The tags don't work here as the script is not installed but there is an example of the result right here.... http://catsnaps.proboards74.com/index.cgi?board=rules&action=display&thread=1138999795&page=1
<script>
//Google It v1.0 [CB]
//Copyright 01-25-2005 ~Wonder
//May be reposted anywhere as long as this header remains in tact
//In loving memory of Tess, the best dog in the world. I'll miss you :'(
//Place in Global Footer
//URL to Google Icon
googleIcon="http://img218.imageshack.us/img218/5996/googleicon5xs.gif";
//Google Safe Search on or off
safeSearch="off";
if(document.postForm && document.postForm.color)
{
document.postForm.color.parentNode.innerHTML+="<a href=javascript:add(\"[google]\",\"[/google]\")><img src=\""+googleIcon+"\" alt=\"Google It\" border=\"0\"></a>";
}
if(location.href.match(/action\=(display|pmview|recent|userrecentposts|gotopost|search|calendarview)/) || (!location.href.match(/action\=/) && document.postForm))
{
td=document.getElementsByTagName("td");
for(i=0;i<td.length;i++)
{
if(td.width=="20%" && td.className.match(/windowbg/))
{
r=td.nextSibling.innerHTML.match(/\[google\](.+?)\[\/google\]/i);
if(r!=null)
{
q=RegExp.$1;
td.nextSibling.innerHTML=td.nextSibling.innerHTML.replace(r[0],"<font style=\"font-family: 'Book Antiqua'\"><font color=0033CC>G</font><font color=CC3300>o</font><font color=DDAA00>o</font><font color=0033CC>g</font><font color=009900>l</font><font color=CC3300>e</font>:</font><a href=\"http://www.google.com/search?hl=en&safe="+safeSearch+"&q="+escape(q.replace(/<\/?.+?>/ig,""+" "))+"\" target=\"_blank\">"+q+"</a>");
i--;
}
}
}
}
</script>
< Message edited by Rocket Boy -- 2/3/2006 16:39:30 >
|
|
|
|
bzmeltzer
Posts: 6 Joined: 11/4/2004 Status: offline
|
RE: Google UBB Tags - 2/2/2006 14:08:54
Join the crowd, buddy, they were gentle with you....public flogging is the least of it. There should be a disclaimer: post at your own risk
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|