. 5 . formscript.php.
1) Dreamweaver form.php. ( 13):
13.
<div id="extra">
<div class="style1" id="top"> </div>
<form name="form1" method="post" action="formscript.php">
:<br>
<input type="text" name="name" id="textfield">
<br> e-mail: <br>
<input type="text" name="email" id="textfield">
<br> : <br>
<input type="text" name="tel" id="textfield">
<br> : <br>
<select name="program" size="1" id="textfield">
<option value="verhniya odejda " selected > </option>
<option value="yazykovye kursy" > </option>
<option value="obuv` "> <option value="tolstovki" ></option>
<option value="futbolki" > </option>
<option value="pidzhaki " > </option>
2) php- formscript.php. mail().
mail() . mail():
boolean mail (string , string , string [, string _])
, , . , _ (, HTML), .
, ( 14):
14.
<?php
//
$d =date("d-m-Y");
// text
$name = $_POST['name'];
$tel = $_POST['tel'];
$email = $_POST['email'];
$program = $_POST['program'];
// textarea
//
// "\r\n" - windows
$additional = str_replace("\r\n", " ",
$_POST['additional'])."\r\n";
//
$result = " ".$d."\n ..: ".$name."\n : ".$email."\n : ".$tel."\n : ".$program."\n . : ".$additional;
// $recipient
$recipient = "[email protected]";
|
|
//
$subject = " ($name)";
//
$headers = "From: $email";
//
mail($recipient, $subject, $result2, $headers) or die("Could not send email!");
//
header("Location: index.php");
?>
3) :
X-Sendmail-Cmdline: sendmail.pl -t -i
Subject: ( . .)
From: [email protected]
14-04-2009
..: . .
: 2258478
: holiday
. : --
, , http://localhost/interteach/.
( 3.7):
. 3.7
php- , . :
Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in Z:\home\localhost\www\Interteach v 3_0\blocks\reklama.php on line 1
, reklama.php 14 . Dreamweaver (. 3.8):
. 3.8
, .
. :
. , ( ) . , , , . -.
, . , .
, -. , -.
:
1. / , ;
2. MySQL ;
3. ;
4. , , . . .)
|
|
5. web-.
web- - Interteach. , , .
, : PHP SQL, .
: web-, , , . (, ) web-;
:
1. , ;
2. CMS web-;
3. web- (Ajax, JQuery . ), web- (CakePHP, CodeIgniter, Drupal), .
.
1. , , PHP 5. Web-. .: -, 2005. . 960. ISBN 5-94157-552-1;
2. , , PHP 5 . .: -, 2005. . 576. ISBN 5-94157-670-6;
3. , PHP. . .: -, 2005. . 1120. ISBN 5-94157-245-;
4. PHP http://www.softtime.ru/bookphp/;
5. PHP 4.0 http://web.ixit.ru/php/tutorial/.
[1]