Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
September 19, 2014, 06:00:13 PM

Pages: [1]   Go Down
  Print  
Author Topic: Embedded javascript not working  (Read 7009 times)
1DollarDean
Newbie
*
Offline Offline

Posts: 2


« on: December 18, 2007, 06:19:36 AM »

Hi Everyone.  This is my first post so I hope I don't mess it up.

I have a very simple line of code that cloaks my affiliate link in the status bar of the browser.

   <p><a href="http://www.tkqlhce.com/click-2669053-10484736" target="_blank" onmouseover="window.status='http://www.vongo.com';return true;" onmouseout="window.status=' ';return true;"><img src="http://www.ftjcfx.com/image-2669053-10484736" width="468" height="60" alt="" border="0"/></a></p>

The code runs fine locally but refuses to work on the server.  I have tested it with both IE7 and Firefox with javascript on.  I've run the code locally on my xampp Apache server and it works fine.  On the Lunarpages server the embedded javascript does not work.    The uploaded html file that contains this line of code runs fine on the server except for the embedded javascript so the file is not corrupt.  I know that javascript actually runs in the browser and not on the server and as far as I know there are no server settings related to javascript so why doesn't it work?

Any help with this problem would be greatly appreciated.  Please keep in mind that I am not a javascript programmer so please keep it simple for my simple mind. Smile

Logged
scanman20
Senior Moderator
▄ber Jedi
*****
Offline Offline

Posts: 1544



WWW
« Reply #1 on: December 18, 2007, 06:43:35 AM »

In terms of Firefox this is a security feature. Window.status is disabled by default from being affected by JavaScript. You can edit your about:config dom.disable_window_status_change but that would only affect you and not your users. Basically this stops people from hiding where links are going to which is what you're trying to accomplish. As for IE7, according to the mdsn blog, "Status Bar Scripting--Scripts will no longer be able to set the status bar text through the window.status and window.defaultStatus methods by default in the Internet and Restricted Zones. This helps prevent attackers from leveraging those methods to spoof the status bar."
« Last Edit: December 18, 2007, 06:46:39 AM by scanman20 » Logged

Even a broken clock is right twice a day.
NotOneBit.com
MCSE - MCSA - MCP
1DollarDean
Newbie
*
Offline Offline

Posts: 2


« Reply #2 on: December 18, 2007, 07:08:13 AM »

Thanks,

You answered my question.

Now what I need is a way to redirect the link.  I use a redirect for several of the links on my website to mask my affiliate links but links that display an image or banner cannot be redirected using any of the methods I've been using.  I understand that the 1px image displayed by some affiliate text links must be displayed for tracking purposes and that keeps me from using a redirect.  So it's back to the drawing board for me and my primative programming skills.  Or I'll just have to leave those ugly affliate links hanging out there in the open.

Thanks again and have a Merry Christmas!
Logged
Pages: [1]   Go Up
  Print  
 
Jump to: