EnglishPages: 1
Hi,
just a post for people who run into the same problem:
I had the problem, that the settings for "Photo properties" in the "Display" tab in "Configuration" -> "Options" were not stored. When I changed them, I got the message, that the changes were saved and an error message, about an error in line 360 of the admin/configuration.php that told me, the deserialization did not work.
So I looked at the database and found a string with a lot of slashes.
The problem was: In line 171 in the admin/configuration.php the values are stored with slashes ("addslashes(...)") in line 360 of the same file, no slashes are expected (and neither are they in the picture view.)
So I changed the line from:
$_POST['picture_informations'] = addslashes(serialize($_POST['picture_informations']));
to:
$_POST['picture_informations'] = serialize($_POST['picture_informations']);
And everything works now.
I'm not sure if the addslashes was necessary in the first place. But be careful with this.
Thank you for reporting the issue PhotoPeter.
I wonder why you have the problem. As fas as I know, you're the first to have this problem.
If you revert to the standard code, do you reproduce the bug?
Offline
Hi,
I'm sorry for my late response.
I deinstalled piwigo a while ago and reinstalled it yesterday. The issue appeared again. And I could solve it with the same change in the code.
A few informations about my setup may help tracking the bug down:
Piwigo 2.2.3
lighttpd/1.4.28
PHP 5.3.5-1ubuntu7.2
sqlite 2.8.17
Maybe it's an issue with sqlite?
I just realised, I have the same problem with the menu. When I changed the order and saved it it had no effect. So I removed the addslashes from line 146 in admin/menubar.php and now it works.
Heres the diff:
146c146 < SET value=\''.addslashes(serialize($mb_conf_db)).'\' --- > SET value=\''.serialize($mb_conf_db).'\'
p.s.: I'm PhotoPeter. I just finnaly made an account.
Offline
maybe it's the same problem as here : [Forum, post 122155 by flop25 in topic 17563] [sqlite] Theme activation on 2.2.1 fails
Can you replace and tell us if it's working ?
Btw can you post an entry in the bugtracker please ? http://piwigo.org/bugs thx
Offline
Yep. Seems to be the same problem. Using pwg_db_real_escape_string() seems to work.
Here's the bug report: http://piwigo.org/bugs/view.php?id=2355
Offline
thx a lot !
Offline
Pages: 1