sala txt 101 200 102 150 103 180

  • Slides: 8
Download presentation

������ sala. txt 101, 200 102, 150 103, 180 104, 600 http: //www. thaiall.

������ sala. txt 101, 200 102, 150 103, 180 104, 600 http: //www. thaiall. com/asp Page: 2

����� (insert. htm) >form action=insert. php> <input name=id> <input name=salary> <input type=submit> </form> http:

����� (insert. htm) >form action=insert. php> <input name=id> <input name=salary> <input type=submit> </form> http: //www. thaiall. com/asp Page: 3

������ (insert. php) ? > $id = $_REQUEST["id; [" $sl = $_REQUEST["salary; [" $f

������ (insert. php) ? > $id = $_REQUEST["id; [" $sl = $_REQUEST["salary; [" $f = fopen("sala. txt", "a"); fputs($f, "$i, $sn; (" fclose($f; ( <? http: //www. thaiall. com/asp Page: 4

����� (delete. htm) >form action=delete. php> <input name=id> <input type=submit> </form> http: //www. thaiall.

����� (delete. htm) >form action=delete. php> <input name=id> <input type=submit> </form> http: //www. thaiall. com/asp Page: 5

������ (delete. php) ? > $id = $_REQUEST["id; [" $ar = file("sala. txt; ("

������ (delete. php) ? > $id = $_REQUEST["id; [" $ar = file("sala. txt; (" $f = fopen("sala. txt", "w; (" for($i=0; $i<count($ar); $i} (++ $ k = split(", ", $ar[$i; ([ if ($k[0] != $id( fputs($f, "$k[0], $k[1 ; ("[ { fclose($f; ( <? http: //www. thaiall. com/asp Page: 6

����� (update. htm) >form action=update. php> <input name=id> <input name=salary> <input type=submit> </form> http:

����� (update. htm) >form action=update. php> <input name=id> <input name=salary> <input type=submit> </form> http: //www. thaiall. com/asp Page: 7

������ (update. php) ? > $id = $_REQUEST["id; [" $sl = $_REQUEST["salary; [" $ar

������ (update. php) ? > $id = $_REQUEST["id; [" $sl = $_REQUEST["salary; [" $ar = file("sala. txt; (" $f = fopen("sala. txt", "w; (" for($i=0; $i<count($ar); $i} (++ $ k = split(", ", $ar[$i; ([ if ($k[0] != $id( fputs($f, "$k[0], $k[1 ; ("[ else fputs($f, "$k[0], $sl". "rn { fclose($f; ( <? http: //www. thaiall. com/asp ; (" Page: 8