User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JavaScript / DHTML / AJAX section within the Web Development category of DaniWeb, a massive community of 391,993 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 4,257 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JavaScript / DHTML / AJAX advertiser: Lunarpages Web Hosting
Views: 618 | Replies: 5
Reply
Join Date: Jun 2008
Posts: 2
Reputation: Funnygirl33 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
Funnygirl33 Funnygirl33 is offline Offline
Newbie Poster

Bypass javascript

  #1  
Jun 13th, 2008
Can anyone help me bypass the following codes?

  1. <script type="text/javascript">
  2.  
  3. if (top.location != location)
  4. top.location.href = document.location.href;
  5.  
  6. </script>
Last edited by peter_budo : Jun 18th, 2008 at 8:36 am. Reason: Keep It Organized - please use [code]tags
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Jan 2006
Posts: 13
Reputation: drago865 is an unknown quantity at this point 
Rep Power: 3
Solved Threads: 1
drago865 drago865 is offline Offline
Newbie Poster

Re: Bypass javascript

  #2  
Jun 13th, 2008
What do you mean by 'bypass'?
Reply With Quote  
Join Date: Jun 2008
Location: Phoenix, AZ
Posts: 535
Reputation: R0bb0b is on a distinguished road 
Rep Power: 2
Solved Threads: 50
R0bb0b's Avatar
R0bb0b R0bb0b is online now Online
Posting Pro

Re: Bypass javascript

  #3  
Jun 13th, 2008
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>
Reply With Quote  
Join Date: Jun 2008
Posts: 2
Reputation: Funnygirl33 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
Funnygirl33 Funnygirl33 is offline Offline
Newbie Poster

Re: Bypass javascript

  #4  
Jun 14th, 2008
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
Reply With Quote  
Join Date: Jan 2006
Posts: 13
Reputation: drago865 is an unknown quantity at this point 
Rep Power: 3
Solved Threads: 1
drago865 drago865 is offline Offline
Newbie Poster

Re: Bypass javascript

  #5  
Jun 14th, 2008
...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:
  1. <script language="javascript" type="text/javascript">
  2. function changeLocation()
  3. {
  4. if (top.location != location)
  5. top.location.href = document.location.href;
  6. }
  7. </script>
Reply With Quote  
Join Date: Jan 2007
Posts: 2,510
Reputation: MidiMagic is on a distinguished road 
Rep Power: 7
Solved Threads: 104
MidiMagic's Avatar
MidiMagic MidiMagic is offline Offline
Posting Maven

Re: Bypass javascript

  #6  
Jun 14th, 2008
Go into your browser settings and disable JavaScript.

Or copy the html file and edit out the code in the copy.
Daylight-saving time uses more gasoline
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb JavaScript / DHTML / AJAX Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the JavaScript / DHTML / AJAX Forum

All times are GMT -4. The time now is 9:51 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC