Jump to content
php.lv forumi

Sakuma nebija pec laika paraadijas


suport

Recommended Posts

<?php

session_start();

if($_SERVER['REMOTE_ADDR']=="89.191.105.7")

{

ini_set('display_errors','On');

}

else

{

ini_set('display_errors','Off');

}

include("inc/config.php");

// Vajadzigais kverijs

if(isset($_SESSION['member_id']))

{

$member_id = $_SESSION['member_id'];

$result = mysql_query("SELECT * FROM lietotaji WHERE member_id=$member_id");

}

 

// Ja sanem pieprasijumu IELOGOTIES

if(isset($_GET['id']) and $_GET['id'] == "login")

{

$logins = quote_smart($_POST['logins']);

$parole = quote_smart($_POST['parole']);

$blockq = 0;

$result = mysql_query("SELECT * FROM lietotaji WHERE username=$logins and password=$parole and blocked=$blockq");

 

// Izvelkam lietotaja ID

$row = mysql_fetch_row($result);

$member_id = $row[0];

 

// Ja šads lietotajs pastav

if(mysql_num_rows($result) == 1)

{

$_SESSION['member_id'] = $member_id;

}

else

{

$nav = "Nepareizs Logins/Parole vai ari akonts ir blokets!";

}

}

?>

 

 

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at C:\AppServ\www\index.php:1) in C:\AppServ\www\index.php on line 2

 

Sakuma viss norm , pec laicinja lietojot web izleca sitas kas pa vainu varetu but

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...