| Index
» Projekty
» phpMyEdit
» Fórum
» bug: set_magic_quotes_runtime(0) deprecated under PHP 5.3.1 |
 |
doug
Založený: 10.02.2003
Príspevky: 1013
Bydlisko: Denver, Colorado (USA)
Zaslal: 2010-01-25 20:21
Návrat hore
Odpovedať s citátom
|
Using PHP 5.3.1 the following message is displayed, presumably because magic quotes are going to be discontinued at some point. Or perhaps there are some functions that are disabled in my PHP development environment.
Error message:
| Kód: |
| Function set_magic_quotes_runtime() is deprecated in phpMyEdit.class.php |
The offending code in phpMyEdit.class.php is
| Kód: |
// Let's do explicit quoting - it's safer
set_magic_quotes_runtime(0);
// Checking if language file inclusion was successful
if (! is_array($this->labels)) {
$this->error('could not locate language files', 'searched path: '.$this->dir['lang']);
return false;
}
// Database connection
if ($this->connect() == false) {
return false;
} |
Temporary work-around is to prefix set_magic_quotes_runtime(0); as @set_magic_quotes_runtime(0);
|
doug
Založený: 10.02.2003
Príspevky: 1013
Bydlisko: Denver, Colorado (USA)
Zaslal: 2010-01-27 04:17
Návrat hore
Odpovedať s citátom
|
Using PHP 5.3 the following issues a "deprecated" warning.
| Kód: |
| $value = ereg_replace("[\r\n\t ]+",' ',$value); |
Does anyone know the exact replacement using preg_replace()?
|
vlad88sv
Založený: 25.01.2010
Príspevky: 3
Zaslal: 2010-04-09 00:17
Návrat hore
Odpovedať s citátom
|
It's preg_replace(), but does not work the exact same way as results are dropped into an array provided in the parameters.
Also REGEX expression is not the same.
Look at it in
http://php.net/manual/en/function.preg-replace.php
Btw, thanks for great sofware, I've been using PME sucesfully at
flor360.com
|
|
Odoslať novú tému
Odpovedať na tému
|
|
|
|