1.get
send link data ( typically search data) to WEB server
php:
send url with "get data" like "test.php?id=11" .
2.post
form data .it also send picture data .
case of PHP :
script must be started with "extract($_POST)" to extract.
script must be started with "extract($_GET)" to extract.
2007年1月30日火曜日
download
$downloadfile = "data.csv";
header("Content-Disposition: attachment; filename=$downloadfile");
header("Content-type: application/octet-stream; name=$downloadfile");
$result = file_get_contents("test.data");
print $result;
header("Content-Disposition: attachment; filename=$downloadfile");
header("Content-type: application/octet-stream; name=$downloadfile");
$result = file_get_contents("test.data");
print $result;
merge for array
there is 2 way to merge for array:
1) use '+'
2) use array_merge()
--
what different is ;
1) '+' is not overwrite on same key
2) array_merge does overwrite
1) use '+'
2) use array_merge()
--
what different is ;
1) '+' is not overwrite on same key
2) array_merge does overwrite
quat strings
it possible to use both " and ' to quat strings .but ' is more use full when you want to write "html codes" .because "html code" often include " .
--
Using " inseide string quat ,pur \ before string.
--
Using " inseide string quat ,pur \ before string.
登録:
投稿 (Atom)
