0

Hi everybody. Am new here and new using PHP as well.
Hope you could help me.
I encountered this error

Error when deleting:
Warning: Unknown: Your script possibly relies on a session
side-effect which existed until PHP 4.2.3. Please be advised that
the session extension does not consider global variables as a
source of data, unless register_globals is enabled. You can disable
this functionality and this warning by setting
session.bug_compat_42 or session.bug_compat_warn to off,
respectively. in Unknown on line 0

Appreciate very much your help.

Thanks,

3
Contributors
4
Replies
5
Views
8 Years
Discussion Span
Last Post by parasp2003
0

The cure for this problem is not to change PHP settings, but rather to update the the script's reliance on register_globals.

Would help if you indicated which script you are using, however clearly it is rather outdated and you should look for something more up to date.


Matti Ressler
Suomedia

0

Hi Matti,
Thanks so much for the reply. Now I can feel that there are people frome the other side of the earth :)
Am a new "trying to learn on my own" programmer and am really having a hard time.
Actually, I don't know yet how to use register_globals.
This is the script I wrote.

session_start();
$id = $_POST;
$_SESSION = $_SESSION;
echo $id = $_SESSION;

Hope you could help me.

Thanks,

The cure for this problem is not to change PHP settings, but rather to update the the script's reliance on register_globals.

Would help if you indicated which script you are using, however clearly it is rather outdated and you should look for something more up to date.


Matti Ressler
Suomedia

0

I think what you are looking for is:

session_start();
$id = $_POST['id'];
$_SESSION['id'] = $id;
echo $_SESSION['id'];

Trying to learn on your own is a very good thing as you don't get locked into notions that "educated" people have.

I made a post earlier today that is similar to this, perhaps you should look at that also.


Matti Ressler
Suomedia

0

<?php
ob_start();
session_start();

?>

when your php script with space create this bug finnaly so not create space in starting php tag

This article has been dead for over six months. Start a new discussion instead.
Take the time to help us to help you. Please be thoughtful and detailed and be sure to adhere to our posting rules.