Does this look ok? - a simple scirpt I did
$addin="the-file-here-.txt";
open(addin,"$addin") ¦¦ print "An Error Occurred";
print "Content-type: text/html\n\n";
while ($line=<addin>)
{
print $line;
}
close(addin);
It is a simple footer executed by
<!--#exec cgi="addin.cgi"-->
I tried it on hypermart before and couldn't get it to work? does it look ok?
----------
[Rob P]
[Email:[email protected]]-[ICQ:16560402]-[Voice Mail:1-877-309-2286]
http://www.thehungersite.com - http://www.therainforestsite.com
http://www.ratemymullet.com - Beauty is only mullet deep.
Anonymous posted this at 17:11 — 13th September 1999.
They have: 5,633 posts
Joined: Jan 1970
also change:
while ($line=<addin>)
to:
while (<addin>)
and use $_ instead of $line.
Assigning a variable to a FILEHANDLE will return only the first line of the file.
Anonymous posted this at 03:56 — 14th September 1999.
They have: 5,633 posts
Joined: Jan 1970
The script seems to be pretty useless. Why dont you just include the textfile in the first place?
Later,
Malte
----------
Malte Ubl - [red]Germany[/red] - http://goKewl.com/
[red]The beats of 1000 hearts inside...[/red] the merciless pulsation... [red]and all I know is I'll be back...[/red] back to trance nation!
anti posted this at 03:47 — 17th September 1999.
They have: 453 posts
Joined: Jan 1999
Hi,
almost all said.
But where is the
use strict;
??
After all it runs on the webserver !!
That will show some additional "flaws" ...
ciao
Anti
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.