Eine kleine Veränderungen der Hauptdatei der Google Shopping Bibliothek gshoppingcontent-php macht die Bibliothek auch unter PHP kleiner 5.3. nutzbar:
einfach ab Zeile 54 die Definition der Konstanten ändern, da nur PHP>5.2 die Defintion von Konstanten mit const ausserhalb von Klassen erlaubt:
define('CLIENTLOGIN_URI' , 'https://www.google.com/accounts/ClientLogin');
/**
* Service name for ClientLogin.
**/
define('CLIENTLOGIN_SVC' , 'structuredcontent');
/**
* Auth scope for authorizing against the Content API for Shopping.
**/
define('OAUTH_SCOPE' , 'https://www.googleapis.com/auth/structuredcontent');
/**
* User Agent string for all requests.
**/
define('USER_AGENT' , 'scapi-php');
/**
* Base API URI.
**/
define('BASE' , 'https://content.googleapis.com/content/v1/');
/**
* Google's endpoint for OAuth 2.0 authentication.
**/
define('AUTH_URI' , 'https://accounts.google.com/o/oauth2/auth');
/**
* Google's endpoint for exchanging OAuth 2.0 tokens
**/
define('TOKEN_URI' , 'https://accounts.google.com/o/oauth2/token');
/**
* Google's endpoint for revoking OAuth 2.0 tokens
**/
define('REVOKE_URI' , 'https://accounts.google.com/o/oauth2/revoke');
