When I visit this page: https://mysite.xyz/mymodule/sale I getting an error:
Fatal error: Uncaught Error: Call to undefined function get_special_key()
An action for https://mysite.xyz/mymodule/sale
public function executeSale() {
$this->redirect('https://auth.sandbox.ebay.com/oauth2/authorize?client_id='.get_special_key('EBAY_CLIENT_ID').'&redirect_uri='.get_special_key('EBAY_REDIRECT_URI').'&response_type=code&scope='.self::EBAY_SCOPES);
// Get the sale pictures
$q = Doctrine_Query::create()
->select('sp.id, sp.pic_order')
->from('SalePicture sp')
->where('sp.sale_id = ?', 606223)
->orderBy('pic_order')
;
$arSalePictures = $q->execute([], Doctrine::HYDRATE_ARRAY);
echo 'SALE PICTURES: ';
print_r($arSalePictures);
}
but, when I visit https://mysite.xyz/mymodule/sale while an acction is like this:
public function executeSale() {
/*
* Some
* Code
* ...
*/
$this->redirect('https://auth.sandbox.ebay.com/oauth2/authorize?client_id='.get_special_key('EBAY_CLIENT_ID').'&redirect_uri='.get_special_key('EBAY_REDIRECT_URI').'&response_type=code&scope='.self::EBAY_SCOPES);
}
everything works as expected.
The get_special_key() function is autoloaded by symfony.
Any suggestions would be helpful, thank you!