Iii-bob. Elektron jurnal dasturiy ta’minotini yaratish texnologiyasi


Bazaga kiritilgan foydalanuvchilar ro`yhati()


Download 0.74 Mb.
bet6/11
Sana08.05.2023
Hajmi0.74 Mb.
#1445534
1   2   3   4   5   6   7   8   9   10   11
Bog'liq
Boshqa mavzudagi shablon

Bazaga kiritilgan foydalanuvchilar ro`yhati()


";echo "";$ta = 1; while($row = mysqli_fetch_array($natijafoy)) { if ($row['role']=='user') { echo ""; } } }//foydalanuvchilar if($_GET['act']=='foydalanuvchi') {echo ' Professor-o`qituvchilar bazaga qo`shish Fanlar bazaga qo`shish Foydalanuvchi Professor-o`qituvchilar yaratish Foydalanuvchi talabalarni yaratish

Foydalanuvchini yaratish

T/rFamiliyasi, ismi va sharifiLoginParolHuquqiAmallar
".$ta++."".$row['name']."".$row['username']." ".$row['password']."".$row['role']." O`chirish
'; }//foydalanuvchini saqlash if (isset($_POST['register_btn'])) {/*tekshirish uchun korib olish*///echo $name."
".$login."
".$role."
".$password_1."
".$password_2;if (($_POST['username']!='')&&($_POST['login']!='')&&($_POST['user_type']!='')&&($_POST['password_1']!='')) { $name = $_POST['username']; $login = $_POST['login']; $role = $_POST['user_type']; $password_1 = $_POST['password_1']; $password_2 = $_POST['password_2']; $royhatibor='yuq';$oqituvchilarni=mysqli_query($conn,'SELECT name FROM foydalananuvchi'); while($row=mysqli_fetch_assoc($oqituvchilarni)){ if ($row['name']==$name) {$royhatibor='bor';$fish=$row['name']; ;}}if ($royhatibor=='yuq') { if ( $_POST['password_1']==$_POST['password_2']) { $sql = "INSERT INTO `foydalananuvchi` (`id`, `name`, `username`, `password`, `role`) VALUES (NULL, '$name', '$login', '$password_1', '$role')"; mysqli_query($conn, "INSERT INTO users(`id`,`name`,`login`,`pass`) VALUES(NULL,'$name','$login',$password_1)"); //mysqli_query($conn, "INSERT INTO users(`id`,`name`) VALUES(NULL,'$name')"); if ($conn->query($sql) === TRUE) { echo "

Download 0.74 Mb.

Do'stlaringiz bilan baham:
1   2   3   4   5   6   7   8   9   10   11




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling