WilliamVenner / LaMetric-Spotify

🔊 Spotify app for La Metric clock
12 stars 3 forks source link

Wrong data format. #2

Closed ikekreham closed 7 years ago

ikekreham commented 7 years ago

Hello,

When i try to validate the URL in my LaMetric App, i get a "Wrong Data Format". lm

I tried to host the pages on 2 differents webserver, when i access the currently_playing.php page, the first one display an error 500 message (nginx + php 5.6 server) and the other one ( apache + php 5.2) replies "Parse error: syntax error, unexpected '[' in /home/www/currently_playing.php on line 3

Any idea how to fix this ? Thank you !

Regards, Matt

WilliamVenner commented 7 years ago

Fixed in https://github.com/WilliamVenner/LaMetric-Spotify/commit/23b2290881667894792a279adc254eab6db48b20

ikekreham commented 7 years ago

After modification, there's another problem:

Fatal error: Call to undefined function getallheaders() in /home/www/currently_playing.php on line 22

WilliamVenner commented 7 years ago

@ikekreham Either update Nginx and PHP or use your Apache server - getallheaders isn't present on all server configurations. I've added error handling for it in https://github.com/WilliamVenner/LaMetric-Spotify/commit/b8a0058f2ee10ae1ca8b443675cdd67b8ebbfcc6 but there is no workaround - you have to use getallheaders to get the Authorization header.