Re: how to write simple scripts

From: Date: Fri, 20 Oct 2000 16:37:46 +0000
Subject: Re: how to write simple scripts
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-21425@lists.php.net to get a copy of this message
just remembered, here is another shell tutorial for your enjoyment : http://www.miester.org/howtos/1 philip -- be outside the box. On Fri, 20 Oct 2000, Nicolas Windpassinger - Sun Microsystems wrote: > HI all, > I have used a lot php in html forms, but is it possible to use a php script > like a normal shell or perl one. > I have been trying with a little example: > > example.php : > > #!/space/server/apache_1.3.12/src/modules/ > <? > $name="nico"; > $age="32"; > $suggestion="toto"; > $mail_id="12"; > $text="blabla"; > > $title = 'Mail Form'; > $msg = 'Name: '.$name."\n"; > $msg .= 'Age: '.$age."\n"; > $msg .= 'Suggestions: '."\n".$suggestions."\n"; > $msg .= 'Mail ID: '.$mail_id."\n"; > $msg .= 'Text: '."\n".$text."\n"; > > mail('nicolas.windpassinger@sun.com',$title,$msg,'From: Whoever > <someone@somewhere.com>'); > > ?> > > then go onto my shell command and do: example.php > > I don't know where the problem comes from:-is php only a html embedded > language? > > -maybe my path is wrong! i also tried with ../modules/php4 > > -the problem should not be the mail. this is just a simple example, but i > would like to have this one right to get on more funny stuff. > > tx, > nicolas > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#21425) next »