function amazon_component_get_cart_creds in Amazon Product Advertisement API 7.2
Return cart credentials (cart ID and HMAC) from the session variable
Return value
Array containing the cart_id and the HMAC, if set. Otherwise FALSE.
File
- amazon_component/
amazon_component.module, line 370
Code
function amazon_component_get_cart_creds() {
if (!empty($_SESSION['cart_id']) && !empty($_SESSION['HMAC'])) {
return array(
'CartId' => $_SESSION['cart_id'],
'HMAC' => $_SESSION['HMAC'],
);
}
return FALSE;
}