PHP va MySQL kodlarining qanday vazifalar bajarishi haqida to'liq yozib boramiz.
Bilganlarimizni qolganlar bilan baham ko'ramiz!
print "$name <br>"; print "$surname <br>"; print "$company <br>";
$great_wines=array("Autstr alia"=> "Clar endon Hills 96", "France"=> "Comte George de Vogue 97", "Austria"=> "Feiler Artinger 97");
$great_labels[0]=Australia $great_labels[1]=F rance $great_labels[2]=Austria
<? foreach($languages as $item){ print "$item <BR>"; } ?>
//bu y erda biz uni hajmini 8 gacha oshirib, yangi yaratilgan hujralarga 100 sonini y ozib chiqishini belgiladik. //$weight=1 , 2, 3, 1 5, 35, 100, 100, 100
//shu yerda biz $weight nin boshiga 100 raqamidan 3 donasini qo'shamiz, yanikim, weight'ning hajmini 8 oshiramiz, va faqat bosh jo ylarni weightning boshiga qoshib qo'yamiz.
print "$a_spice[0] $a_spice[1] <br>"; print "$a_spice[0] $a_spice[1]";
function delete_dupes($element){ static $last=""; if ($element==$last) { } $last=$element
//rev_machine="BMW", "Mitsubishi", "DONG" kabi qiymatlarni oladi.
//shunda tes_til'ning qiymati quyidagicha bo'ladi tes_til="French"=>"France", "Uzbek"=>"Uzbekistan", "English"=>"England"
//params_c="PA"=>3, "MA"=>2, "CA"=2, "MO"=>1 , "CO"=>1 kabi qiyamtlarni oladi.
cities[2]=Andijan cities[1]=Samarkand cities[0]=Tashkent cities[4]=Qarshi
//ar4="a", "b", "c", ... "i" mana shu holga keladi, yani a1 , a2, a3 larni qo'shib qo'yadi.
echo "$chiqar "; }
<?php // agarda $input 2 bo`lsa array("qizil", "yashil") chiqaradi // agarda $input 1, -1 bo`lsa array("qizil", "oq") chiqaradi ?>
print "File $filename does not exist!"; endif;
$file = "test.txt"; print "The file $file is valid and exists!"; else: print "The file $file does not exist or it is not a valid file!"; endif;
print "Pastry.txt is $fs bytes.";
$file = "userdata.txt"; else: print "File $file does not exist!"; endif;
<? $data = "08:13:00 | 12:37:12 | 208.247.106.87 | win98"; $filename = "test.txt"; else: print "Could not open $filename for writing"; endif; ?>
print $file;
print $char; endwhile;
print $line; endwhile;
<? endwhile; ?>
<? $file = "test.txt"; ?>
<? $fh = popen("grep Toshkent < test.txt", "r"); //Biz bu yerda Unix sistemasidagi grep buyrugini ishlatib test.txt faylidan Toshkent so'zini qidiradi va uni topgan qatori ekranga chiqaradi ?>
<? if (!$fp){ echo "$errstr ($errno)<br>\n"; } ?>
<? print "<br>$ping[$i]"; endfor; ?>
$output = 'ls'; print "<pre>$output</pre>";
$user_in = 'rm rf *'; $user_in = 'rm rf *';
$path = "/usr/local/sbin/skip.test";
$file = "datafile.txt"; print "$file is $size bytes. <br>"; print "Last access time: $atime<br>"; print "Last modification time: $mtime <br>";
00
00
$data_file = "data1.txt";
$path = "/usr/local/index.php";
$file = "index.html"; $dirs = "/usr/local";
<? $access = "hits.txt"; $current_visitors = $visits[0]; $all_me = (int)$current_visitors + 1; print "Visited: $all_me"; ?>
<html> <head> <title> Yuklandimi? </title> </head> <body> <?php echo("Fayl yuklandi"); } else { echo("Fayl yuklana olmadi"); } ?> </body> </html>
<html> <head> <title> Fayl yuklandimi? </title> </head> <body> <?php echo("yuklandi <br>"); echo("Fayl bilan aloqali malumotlar: <br>"); echo("Ismi: " ) ; echo($_FILES["filename"]["name"]) ; echo("<br>Hajmi: ") ; echo($_FILES["filename"]["size"]) ; echo("<br>Yuklangan yeri: " ) ; echo($_FILES["filename"]["tmp_name"]); echo("<br>Fayl turi: " ) ; echo($_FILES["filename"]["type"]); } else { echo("Yuklanmadi"); } ?> </body> </html>