tuto : automatic open link in new tab
Posted 3/14/11 // 11:15 PM
pagi ini aku dengan baiknya nak buat tutorial automatic open link in new tab bagi pengguna pengguna blog diluar sana . apa itu automatic open link in new tab ? macam ini , bila korang bukak link , dia terus automatic pergi ke new tab . senang sikit bagi pelawat2 blog . :) . jom ikut tutorial dia. and credit untuk meira.

--------------

1. Dashboard > Design > Add Gadjet > HTML/JavaScript
2. Paste code bawah nie dalam Content

<!-- code for turning all non-blog links to new page links -->
<script type="text/javascript" language="javascript">
var arr = document.getElementsByTagName("a"); //get all links in the page
for(var i = 0; i < arr.length; i++)
{
if(arr[i].href.indexOf("Your URL") < 0 //not links that are 'inside' blog
&& arr[i].href.indexOf("javascript:") < 0) //not javascript links
arr[i].target = "_blank";
}
</script>
3) tekan save ! and try bukak link blog korang ;)




Photobucket
5 Comments:
Blogger mia.lia said...

haihhh..baru bgun tido ke..
da ptang da..hehe

March 14, 2011 at 11:26 PM  


Blogger beela said...

haha.. eyerp.. :P

March 14, 2011 at 11:28 PM  


Blogger izzah said...

thanks ye

March 15, 2011 at 7:35 AM  


Blogger beela said...

welcome :)

March 18, 2011 at 3:48 AM  


Blogger bbBunny93 said...

thanks for tuto :)

March 18, 2011 at 4:13 AM  


Post a Comment

... Back to the blog?

Since 2012