הוסטס - פורום אחסון האתרים הגדול בישראל

הוסטס - פורום אחסון האתרים הגדול בישראל (https://hosts.co.il/forums/index.php)
-   פורום תיכנות (https://hosts.co.il/forums/forumdisplay.php?f=14)
-   -   למי שמבין ב sql - צריך עזרה קלה! (https://hosts.co.il/forums/showthread.php?t=74695)

israeli 20-05-09 03:16

למי שמבין ב sql - צריך עזרה קלה!
 
ב"ה

בניתי את הקוד php שמתחבר למסד הבעיה שלא אבנתי איזה טבלות אני צריך לפתוח ידנית בפנהל php
ממש תודה רבה!
זה הקוד:
PHP קוד:

<?php
include('mysql.php');

$fname $_POST['fname'];
$password $_POST['pass'];

$pass1 md5($password);
$pass sha1($pass1);

$select mysql_query("SELECT * FROM `admins` WHERE fname='$fname'");
$cu mysql_fetch_array($select);

if (!empty(
$_COOKIE['adv_U_a']) AND !empty($_COOKIE['adv_P_a']))
{
echo 
"אתה כבר מחובר לפאנל הניהול!";
}
else
{
if (!empty(
$username) || !empty($password))
{
if (empty(
$cu))
{
?>
<font color="darkred"><b>
שגיאה - השם  הפרטי שהכנסת לא קיים במערכת
</b></font>
<br><br>
<input type="button" value="חזור אחורה" onclick="window.location.href='javascript:window.history.back(-1)';">
<?php
}
else if (
$pass == $cu['password'])
{
setcookie('adv_U_a',$fname);
setcookie('adv_P_a',$pass);
header'Location: index.php' );
}
else
{
?>



כל הזמנים הם GMT +2. הזמן כעת הוא 21:00.

מופעל באמצעות VBulletin גרסה 3.8.6
כל הזכויות שמורות ©
כל הזכויות שמורות לסולל יבוא ורשתות (1997) בע"מ