Unstoppable Domains โ€” AI Assistant

Stop frame breakers

NamecheapNamecheap
Watch

teclance

Established Member
Impact
1
Hi guys!

I am working on a java code to stop users from using a frame breaker when surfing for credits. I am almost there but it still isn't bullet proof.

Here is the code I am using so far:

<script language="Javascript">
<!--
var your_message = "Do you really want to leave this page? Click yes if you want to or click cancel if a frame breaker caused this pop up.";
var times = 0;

function onul() {
if (times == 0) {
var leave = confirm(your_message);
if (!leave) location = self.location;
times++;
}
}

//-->
</script>
<body onunload="onul()">


When the user clicks cancel it is suppose to take the user back surfing but it ends up going to the frame breakers site.

Here is a sample frame breaker code many use:

<script language="Javascript">
<!--

if (top.location != self.location) {
top.location = self.location.href
}

//-->
</script>



If you can assist thank you so much also any other suggestions are welcomed!
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
Unstoppable Domains โ€” AI StorefrontUnstoppable Domains โ€” AI Storefront
You're trying to achieve the impossible.

The reason your script doesn't work is because no browsers allow you to stop someone from navigating away from a page. Imagine ending up on a porn site, and you couldn't get off the page.

Anyway, sorry, but 'frame-breakers' are unbreakable (unless you filter the code through, which is in breach of other sites' legal rights, and is very inpractical).
 
0
•••
CatchedCatched
Escrow.com
Spaceship
Rexus Domain
CryptoExchange.com
Domain Recover
CatchDoms
DomainEasy โ€” Live Options
DomDB
  • The sidebar remains visible by scrolling at a speed relative to the pageโ€™s height.
Back