- Forums
- HTML
- Secutiry Prevent Frames From Search Engine Images Stop Picture Frame Busting
This Page Contains information about Secutiry Prevent Frames From Search Engine Images Stop Picture Frame Busting By wallpaperama in category HTML with 0 Replies. [706], Last Updated: Sat May 18, 2024
wallpaperama
Mon Jun 18, 2007
0 Comments
348 Visits
today i learned something useful, i always watched my stats on my website. and for a while i've noticed that more and more of my traffic comes from search engines for my images.
for example, this is what i see most of the time:
http://images.google.com/imgres?imgur...
i've visited some site that when you are viewing their images, my browser closes the top frame of the page and leaves the bottom one open only. and i wondered how they do that because that would really help on my website because most of the people looking for pictures on search engines are most likely to steal them from your site.
so today i found out how i can close the top frame and leave the bottom frame open. its called "Frame Busting" i learned this term just today. which makes sense cuz you are busting out the frames on your browser.
i would really like to do it with PHP instead of javascript, but at this time i only know how to do this with javascript, so if the visitor has havascript not enabled, then that means that it won't work. but at least its a start. so here is how you do it.
put this code in between your <head> </head> tags:
<script language="JavaScript">
<!--
function framebust()
{
if (top !=self)
top.location=self.location;
}
-->
</script>
now all you have to do is put this in you body tag so it would look like this
<body onload="framebust(); return true">
that's it. hope you learned from this. thanks to the people at webune for their support on this. they helped me on my dedicated server and they also helped me with this question.
thanks Webune.com