Function set_magic_quotes_runtime() is deprecated

Found a bug? Tell us!!
Post Reply
konus
Regular
Posts: 334
Joined: Mon Jun 16, 2008 1:57 pm
Location: Dresden, Germany
Contact:

Function set_magic_quotes_runtime() is deprecated

Post by konus »

Hello, in my blog I have the error

Code: Select all

Deprecated: Function set_magic_quotes_runtime() is deprecated in /usr/share/php/Cache/Lite.php on line 718 Deprecated: Function set_magic_quotes_runtime() is deprecated in /usr/share/php/Cache/Lite.php on line 728
it is near the freetag-plugin.

1. is this something from serendipity? I cant find the path /usr/share/php/Cache/ . I only found /serendipity/bundled-libs/Cache/Lite.php

2. what can I do? I use PHP Version 5.3.6 at the moment. "magic_quotes_runtime" ist set to "Off"

Update: the bundled Lite.php ist v 1.54 2009/07/07. I found a newer one 1.7.12, but

Code: Select all

set_magic_quotes_runtime(0);
ist still in use in this newer version
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Function set_magic_quotes_runtime() is deprecated

Post by garvinhicking »

Hi!

When serendipity detects a PEAR installation on your server, it prefers this over the bundled library. On your server, that is the case. Thus, you need to update your PEAR packages (or remove them).

Or you can edit the serendipity_config_local.inc.php and insert $serendipity['use_PEAR'] = false.

Reading your update - I didn't know this wasn't fixed. You might want to edit your php.ini and set the error_Reporting so that E_DEPRECATED does not raise a visible warning.

HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
konus
Regular
Posts: 334
Joined: Mon Jun 16, 2008 1:57 pm
Location: Dresden, Germany
Contact:

Re: Function set_magic_quotes_runtime() is deprecated

Post by konus »

Thank you for the very fast answer!

I inserted in serendipity_config_local.inc.php

Code: Select all

$serendipity['use_PEAR'] = false;
but still get the error pointing to /usr/share/php/Cache/Lite.php

I also tried a php.ini (and think, my hoster recognized them) with

Code: Select all

error_reporting = E_ALL & ~E_DEPRECATED
and in .htaccess

Code: Select all

<IfModule mod_php.c>
     php_value error_reporting  1
</IfModule>
but nothing helped. I am waiting for the replay of my hoster now.
littlerabbit
Regular
Posts: 15
Joined: Thu Nov 09, 2006 6:41 pm
Contact:

Re: Function set_magic_quotes_runtime() is deprecated

Post by littlerabbit »

Same issue. Tried disabling PEAR in the config file as well as .htaccess and php.ini. Still getting tons of deprecated errors.

This is a reply from my host. Maybe this will help you also.
The problem is that your application is not compatible with PHP 5.3 It is using a function that is deprecated. We configured the website with PHP 5.2 by adding the following code to the .htaccess file at the /[application-directory]/ directory:

AddHandler application/x-httpd-php52 .php

The website is no longer throwing errors.

Note that this will only be a temporary fix, until we stop PHP 5.2.

You need to obtain an updated version of your theme that is compatible with PHP 5.3. Then, you can set up the website with PHP 5.3 by removing the code that we added to the .htaccess file.
Post Reply