Jump to content

if()help


corillo181

Recommended Posts

so you saying A SESSION UPDATES AUTOMATICLY?when you got a site and something is passed by session dont you need to refresh that person session?

becuase it only seen to wokr when the session is destroy and is stared again.. and i seen logicly, becuase if the session is already going is going to have the same value that is passed on when a user log in :S..

is there any way i can send the user back to the usercheck to give them the newly update session info and then take them back to the page that they came from?
Link to comment
Share on other sites

What do you mean by restart that person session? You can change a persons session anywhere in your script such as you can do this:
[code]<?php
session_start();

$_SESSION['lvl'] = "Something";

//some other code here

$_SESSION['lvl'] = "hello world";

?>[/code]
When you run that code first PHP will set the lvl session to 'Something' then further down PHP will rewrite the lvl session to 'hello world'. You dont need to destorythee session and then reset the session if you are chaning something in the session! You only do that when you are using cookies.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.