Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Browser Inserted Script?

Status
Not open for further replies.

KABUSA

Technical User
Mar 9, 2004
17
US
A customer reported a page that would not load. "white screen". I asked him to send me a copy of the source code.
It revealed some added script that is not a part of my own page. Some in the <HEAD> and Some after the </HTML>
Here is the added script. Does anyone recognize the origin and what it is supposed to do? Thanks Kevin.
PS: The code was triggering on a syntax error on my page.
With that fixed the page loads properly.

<script language="JavaScript">
<!--
function SymError()
{
return true;
}

window.onerror = SymError;

var SymRealWinOpen = window.open;

function SymWinOpen(url, name, attributes)
{
return (new Object());
}

window.open = SymWinOpen;

//-->
</script>

</HEAD>
<BODY>
</BODY>
</HTML>

<script language="JavaScript">
<!--
var SymRealOnLoad;
var SymRealOnUnload;

function SymOnUnload()
{
window.open = SymWinOpen;
if(SymRealOnUnload != null)
SymRealOnUnload();
}

function SymOnLoad()
{
if(SymRealOnLoad != null)
SymRealOnLoad();
window.open = SymRealWinOpen;
SymRealOnUnload = window.onunload;
window.onunload = SymOnUnload;
}

SymRealOnLoad = window.onload;
window.onload = SymOnLoad;

//-->
</script>
 
Looks like you might be using a free webhost which inserts ads into your pages. I would assume that SymReal would refer to RealPlayer or something, but who knows. That script seems to hide all JavaScript errors so I'd assume it's being sneaky. If the code is automatically inserted into each of your pages, you can kill it by learning exactly where it implants itself and trapping it in between a set of NOSCRIPT tags.
 
The customer tells me he uses optimum online as his internet provider.

Kevin

 

The code is inserted by a Symantec firewall product. Ask the customer to disable this and see if the problem goes away.

Hope this helps,
Dan
 
Hi,
Thanks, that is what I thought actually since he is using a cable service.
I noted in my original post that I did actually have a typo on my page. the script hiding lines had an error
the top was ok as <!--
but the bottom one was missing the closing >
//-- was all I had.
I never caught it when testing; the browsers I use ignored it. But with the extra code inserted by his firewall, it now triggered on that missing > and would not load the page. In fact, I tested it (with the error) in netscape(Which shows the translated html) and found that it was converting the content into something called <XMP>. Don't know what that is, but either way, it is no longer a problem now.

Thanks
Kevin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top