[PHP] Re: Help with my code

2003-06-18 Thread Terje Torkelsen

To echo multiple lines you have to write 

echo END


html
headtitle 


...
..

END;

and in the beginning you have

if( $action ) {
 if...
 elseif ..
 elseif..
 
 if( $action ) {  = why this? you have already checked if $action is true 
earlier...

 }

}

(nb! posting the what the error is might help solve a problem)


On Wed, 18 Jun 2003 17:09:18 +0200, Mark Clarkstone wrote
(in message [EMAIL PROTECTED]):

 why won't this write?
 
 ?
 require (config.php);
 if ($action) {
 
 If ($name==) {
 echo Form Error  No Name;
 echo $errorbk;
 }
 else if ($email==) {
 echo Form Erorr  No e-mail;
 echo $errorbk;
 }
 else if ($input==) {
 echo Form Error  No Comment found;
 echo $errorbk;
 }
 else if ($wb==1) {
 mail($webemail, $subject, $input);
 }
 if ($action) {
 $data = $name\n$email\n$input;
 $fp = fopen(messages.txt,'a');
 $fw = fwrite($fp,$data,$subject);
 fclose($fp);
 echo Thank you;
 }
 }
 else if (!$action) {
 echo html
 
 head
 meta name='GENERATOR' content='Microsoft FrontPage 5.0'
 meta name='ProgId' content='FrontPage.Editor.Document'
 meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'
 title$pagetitle/title
 /head
 
 body
 
 form method='POST' action='?action=send'
 p align='left'font face='Tahoma'font size='2'Commentie Version
 1.0/fontbr
 font size='2'Your Name /font
 input type='text' name='name' size='20' style='font-family: Tahoma;
 font-size: 10pt'br
 font size='2'Your E-mail/fontinput type='text' name='email' size='20'
 style='font-family: Tahoma; font-size: 10pt'br
 font size='2'Your msg / comment/fontbr
 textarea rows='2' name='input' cols='20' style='font-family: Tahoma;
 font-size: 10pt'/textareabr
 /font
 font size='2' face='Tahoma'e-mail amp; save /fontfont face='Tahoma'
 select size='1' name='wb' style='font-family: Tahoma; font-size: 10pt'
 option selected value='1'Yes/option
 option value='0'No/option
 /select/font/p
 /p
 p align='left'
 font face='Tahoma'
 input type='submit' value='Submit' name='B1' style='font-family: Tahoma;
 font-size: 10pt'input type='reset' value='Reset' name='B2'
 style='font-size: 10pt; font-family: Tahoma'/font/p
 /form
 
 /body
 
 /html;
 }
 ?
 
 
 
 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Help with my code

2003-06-18 Thread Lars Torben Wilson
On Wed, 2003-06-18 at 08:23, Terje Torkelsen wrote:
 To echo multiple lines you have to write 
 
 echo END
 
 
 html
 headtitle 
 
 
 ...
 ..
 
 END;

No offense, but this is completely false. Double-quotes will work just
fine.


-- 
 Torben Wilson [EMAIL PROTECTED]+1.604.709.0506
 http://www.thebuttlesschaps.com  http://www.inflatableeye.com
 http://www.hybrid17.com  http://www.themainonmain.com
 - Boycott Starbucks!  http://www.haidabuckscafe.com -




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: Help with my code

2003-06-18 Thread Terje Torkelsen
hehe.. know, i seem to write it a little fast.. it a _long_ time since ive 
use this notation.. :)

im gonna check it to be sure next time..

On Wed, 18 Jun 2003 17:45:26 +0200, Lars Torben Wilson wrote
(in message [EMAIL PROTECTED]):

 Organization:
 MIME-version: 1.0
 X-Mailer: Ximian Evolution 1.2.3
 Content-type: text/plain
 Content-transfer-encoding: 7BIT
 References: [EMAIL PROTECTED]
  [EMAIL PROTECTED]
 Subject: Re: [PHP] Re: Help with my code
 From: [EMAIL PROTECTED] (Lars Torben Wilson)
 
 On Wed, 2003-06-18 at 08:23, Terje Torkelsen wrote:
 To echo multiple lines you have to write 
 
 echo END
 
 
 html
 headtitle 
 
 
 ...
 ..
 
 END;
 
 No offense, but this is completely false. Double-quotes will work just
 fine.
 
 
 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php