Jump to content

Archived

This topic is now archived and is closed to further replies.

newuser101

Deprecated: Function session_is_registered() is deprecated

Recommended Posts

hi

 

i am new with OS Commerce

 

i have got this problem

 

" Deprecated: Function session_is_registered() is deprecated "

 

and i can not add products in my shopping cart also banner and few buttons (including checkout) are missing.

 

 

My PHP version 5.3.0

Mysql version 5.1.36

Apache Version 2.2.11

register_globals = off

safe_mode = off

 

 

please give me an idea how to solve the provlem

 

 

Thanks

 

regads

newuser101

Share this post


Link to post
Share on other sites

Its due to the version of php on your server,

 

In includes/application_top.php and admin/includes/application_top.php

 

find:

 

 //set the level of error reporting
 error_reporting(E_ALL & ~E_NOTICE);

 

replace with:

 

//set the level of error reporting
error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);


Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Share this post


Link to post
Share on other sites

It may also be due to the version of osCommerce in this case. The RC2a sessions file should not call session_is_registered in PHP versions of 4.3 or higher (and it's 5.3 that gives that warning):

  function tep_session_is_registered($variable) {
if (PHP_VERSION < 4.3) {
  return session_is_registered($variable);
} else {
  return isset($_SESSION) && array_key_exists($variable, $_SESSION);
}
 }

Updating to the RC2a sessions file would fix this as well. It looks API compatible with the older file. So it should work as a drop in replacement, but I haven't tested it. Even better, if this is a new install, then start over with RC2a.


Always back up before making changes.

Share this post


Link to post
Share on other sites

×