Solved

sessions won't work

Posted on 2004-09-07
2
230 Views
Last Modified: 2006-11-17
i have a linux / unix host and i can't get sessions to work. i am using this variable

$_SESSION['Login']

i am just trying a simple echo

echo $_SESSION['Login'];

i don't get anything why?
0
Comment
Question by:Paul S
2 Comments
 
LVL 25

Accepted Solution

by:
Marcus Bointon earned 50 total points
ID: 12003902
You have called session_start() before this haven't you? You have put something into $_SESSION['Login'] that's visible?
0
 
LVL 11

Author Comment

by:Paul S
ID: 12017687
thank you for your help. I was making a dumb mistake. i am fairly new to php. I was calling session_start() on the page that i created the session variable on, but i wasn't calling session_start() on the page the was suppose to read the variable. I just added session_start to an include file and included it at the start of every page.
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now