Closed Thread Icon

Preserved Topic: More Perl Help... (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=17807" title="Pages that link to Preserved Topic: More Perl Help... (Page 1 of 1)" rel="nofollow" >Preserved Topic: More Perl Help... <span class="small">(Page 1 of 1)</span>\

 
foam
Bipolar (III) Inmate

From: Fontana, Ca, USA
Insane since: Jun 2000

posted posted 06-20-2000 02:37

Hey all, I changed what you said to change in the last message, but it didnt work yet, can anyone tell me what else i could do to make this work? i wanna get this to write to the file...

#!/usr/bin/perl
use Strict;

#############################
#
# This Forum copyright Scott Hedstrom
# No unauthorized Use.
#
#############################
#
# Start of Development: June 15, 2000
# End of Development: TBA
#

#Define These Variables

$forumname="foamFORUM" #The name of the forum here

$outputfile="foruminput.txt" #This file is where the script will write to. Use it for an SSI

$sendsite="http://panzone.com/foam/forum.shtml"> #The location you want themto be sent after message submition.

# This creates an instance of the CGI object.

$cgiobject = new CGI;

# This gets the values of forms submitted by the user.

$username=$cgiobject->param("username");

$message=$cgiobject->param("message");

# End of Variable Info

#Opens the Output file for input.

open(outfile, ">$outputfile") &#0124; &#0124; die;

# End of File copying

#Start of file writting.

print outfile "$message\n\n\n";

close(outfile); #Closes the file.

# Creates the webpage

print "<HTML><HEAD><TITLE>$forumname</TITLE></HEAD>
<BODY>Message Submitted.</BODY></HTML>"

thanks alot guys

foam
www.thefoam.org

WarMage
Maniac (V) Mad Scientist

From: Rochester, New York, USA
Insane since: May 2000

posted posted 06-20-2000 03:14

When you are printing to a webpage on the fly you have to define it.

print $cgiobject->header;

This should go before all of ur HTML jargon.

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 06-20-2000 18:56

Um in this version you don't have the 'use CGI' statement.

« BackwardsOnwards »

Show Forum Drop Down Menu