Why do we use session?
No Answer is Posted For this Question
Be the First to Post Answer
hi guys..i m new to php..and want to learn it including the oops concept...can anybody send me some good programming bases exercise or a small learning project on it at nitsl_a@yahoo.co.in.I know html and going thru some of its websites.But about to go on it practically.plz advice.
1 Answers College School Exams Tests, Satas, Wipro,
How to remove white spaces from the beginning and/or the end of a string in php?
i start a new session with : session_start(); then i set some session variable like this : $_SESSION['name']=$_POST['name'];\ and some another variables. at bottom of page i set header to diffrent page : header('location: index.php'); exit(); now in new page (index.php i can't access to my session variables, like $_SESSION['name']) what's wrong ? thanks. here is my files : a.php ======================================== session_start(); require ('config.inc.php'); if(isset($_POST)) foreach($_POST as $v=>$k) { $items[$v]=$k; } $sql="SELECT * FROM members WHERE username='{$items['user']}' AND pass=MD5('{$items['Password']}') "; $res=mysql_query($sql); $row=mysql_fetch_assoc($res); if($row['username']) { $_SESSION['type']=$row['type']; $_SESSION['name']=$row['name']; $_SESSION['family']=$row['family']; $_SESSION['username']=$row['username']; $_SESSION['date']=$row['date']; } header('location: admin.php'); exit(); ====================================== admin.php ===================================== <?php session_start(); if(!isset($_SESSION['admin'])) { header('location: index.php'); exit(); } require ('config.inc.php'); ?> . . . =================================
how to select single row from table and insert into same table as a new record by using a single sql query.
What types of images that PHP supports?
can any please tel me about "Expression Engine"
Tell me how is it possible to propagate a session id?
What is abstract class in php?
Does wordpress run on php 7?
What are encryption functions in php?
What does pear stand for?
Is array empty php?