0

Can anyone help me bypass the following codes?

<script type="text/javascript">
    
        if (top.location != location)
            top.location.href = document.location.href;
            
    </script>
4
Contributors
5
Replies
6
Views
9 Years
Discussion Span
Last Post by MidiMagic
0

if what you mean by bypass is ignore, this is how you would do it.

<script language="javascript" type="text/javascript">

/* if (top.location != location)
top.location.href = document.location.href; */

</script>
0

I mean that code is in my html page, but I need to find a way to prevent the browser from executing it, without changing the code itself

0

...why can't you change the code? I was going to say you could just put it inside a function then call that function whenever you actually do need to execute it. Like this:

<script language="javascript" type="text/javascript">
function changeLocation()
{
     if (top.location != location)
     top.location.href = document.location.href;
}
</script>
0

Go into your browser settings and disable JavaScript.

Or copy the html file and edit out the code in the copy.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.