Piwigo / piwigo-openstreetmap

OpenStreetMap integration for Piwigo
http://piwigo.org/ext/extension_view.php?eid=701
GNU General Public License v3.0
35 stars 35 forks source link

Parse/Syntax Errors in Edit Photo [Properties] and OpenStreetMap Plugin [Configuration] #107

Open tazmaton opened 8 years ago

tazmaton commented 8 years ago

When I go to Edit Photo [Properties] on an image and click on the "OpenStreetMap" tab, I get the following error message:

Parse error: syntax error, unexpected '[' in /app/piwigo/plugins/piwigo-openstreetmap/admin/admin_photo.php on line 145

Also, when I go to OpenStreetMap Plugin [Configuration] and click on the "Tags" tab I get the following error message:

Parse error: syntax error, unexpected '[', expecting ')' in /app/piwigo/plugins/piwigo-openstreetmap/admin/admin_tag.php on line 80

Thanks.

xbgmsharp commented 8 years ago

Could you please specify the PWG version and the plugin version as well as your PHP and OS version. I am not able to reproduce the issue.

tazmaton commented 8 years ago

Hello,

I’m running Piwigo version 2.8.1, OpenStreetMap version 2.8.b, Google Chrome version 51.0.2704.106 (64-bit), Mac OS X version 10.11.3, PHP version 5.3.3 .

Thanks.

xbgmsharp commented 8 years ago

That is weird, I use HP 5.6.x. PHP 5.3 is quite old but should work.

https://github.com/xbgmsharp/piwigo-openstreetmap/blob/master/admin/admin_tag.php#L80 https://github.com/xbgmsharp/piwigo-openstreetmap/blob/master/admin/admin_photo.php#L145

If you check the line of the code involve, the error message, does not make much sense.

For admin/admin_photo.php#L145 you should have the error twice. You could try to replace [] by array() eg:

$list_of_places = array()
tazmaton commented 8 years ago

Well, I’m not a programmer, just a user of Piwigo, so I would not know how to incorporate that.

xbgmsharp commented 7 years ago

Would you be able to confirm the line you are seeing the error? In addition Piwigo version, OpenStreetMap version and PHP version?

xbgmsharp commented 7 years ago

With the merge of #117, would you be able to confirm you still see the error?