Gossamer Forum
Home : General : Perl Programming :

Javascript..

Quote Reply
Javascript..
Hi. Does anyone know of any code I could use to display a banner. I wont line out IFRAMES and ILAYERs, but basically all I need to do is call http://www.tier1host.net/...er.com/adverts/ad.pl via a Javascript call (this will just be a normal page, no SSI or anything).

Anyone got any ideas?

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [AndyNewby] Javascript.. In reply to
<script language="Javascript" src="http://bla"></script>

Last edited by:

RedRum: Nov 8, 2001, 2:18 PM
Quote Reply
Re: [RedRum] Javascript.. In reply to
Ok, maybe I'm being stupid here, but I tried the following and it gave me a javascript error Frown

Code:
<html>

<head>
<title>Test</title>
</head>

<body><script language="Javascript" src="http://www.tier1host.net/~ace-installer.com/adverts/ad.pl"></script>
</body>

</html>

Any ideas?

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [AndyNewby] Javascript.. In reply to
Hi Andy:

Give this a whirl. Try modifying the ad.pl script to produce output as shown in attached file. I removed noscript portion since the script is called via JavaScript (JS) - if you don't have JS enabled, then ad.pl not called, and noscript HTML would not display.

Dan Cool


----
Cheers,

Dan
Founder and CEO

LionsGate Creative
GoodPassRobot
Magelln
Quote Reply
Re: [AndyNewby] Javascript.. In reply to
Hi,

The html code is ok. However, the ad.pl file should firstly response the following line or something like this

print "Content-type: application/x-javascript";

Cheers,


Cheers,

Dat

Programming and creating plugins and templates
Blog
Quote Reply
Re: [] Javascript.. In reply to
True enough. Both will work - forgot about the application/x-javascript header (simpler solution - I was thinking in terms of calling like external javascript rather than CGI). But the noscript is nonsensical - at least in terms of the script being called via JS.


Dan Cool