| Programming PHP | PERL | ASP| ColdFusion| C++ Chat with other forum members about programming. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
I seriously do not have a clue about perl but i need a piece of software which will email a link to the email adresse the user put in using sendmail. I have put together a script which sends the email and one which will store the info to a log file. The script doesn't work and i don't have a clue why. i've included my script below, if you can find possible errors please help me to correct them,ThanksIanPerl Script--------------------------------------#!/usr/bin/perluse CGI;# Create the CGI objectmy $query = new CGI;# Output the HTTP headerprint $query->header ( );# Capture the form resultsmy $senderemail = $query->param("senderemail");my $sendername = $query->param("sendername");my $reciplentsemail = $query->param("reciplentsemail");my $reciplentsname = $query->param("reciplentsname");my $message = $query->param("message");$dateandtime = time();# Email the form resultsopen ( MAIL, "| /usr/sbin/sendmail -t" );print MAIL "From: $senderemail\n";print MAIL "To: $reciplentsemail\n";print MAIL "Subject: \n";print MAIL "\n";print MAIL "\n.\n";close ( MAIL );$filename = "Log file location here";open(FH, ">>$filename"); print FH "$dateandtime | $sendername | $senderemail | $reciplentsname | $reciplentsemail\n";close(FH);# Thank the userprint
|
|
|||
|
|
![]() |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
All times are GMT. The time now is 09:48 AM.
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
Ad Management by RedTyger





Linear Mode
