Advertisement
Guest User

Untitled

a guest
Mar 29th, 2016
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.15 KB | None | 0 0
  1. <?php
  2.  
  3. header("Access-Control-Allow-Origin: *");
  4. header("Access-Control-Allow-Credentials: true");
  5.  
  6. /* Init the OXID Framework */
  7.  
  8.  
  9. if (defined('E_DEPRECATED')) {
  10.     //E_DEPRECATED is disabled particularly for PHP 5.3 as some 3rd party modules still uses deprecated functionality
  11.     error_reporting(E_ALL ^ E_NOTICE ^ E_DEPRECATED);
  12. } else {
  13.     error_reporting(E_ALL ^ E_NOTICE);
  14. }
  15.  
  16.  
  17. if (!defined('OX_BASE_PATH')) {
  18.     define('OX_BASE_PATH', dirname(__FILE__) . DIRECTORY_SEPARATOR);
  19. }
  20.  
  21. // custom functions file
  22. require_once OX_BASE_PATH . 'modules/functions.php';
  23.  
  24. // Generic utility method file including autoloading definition
  25. require_once OX_BASE_PATH . 'core/oxfunctions.php';
  26.  
  27. //sets default PHP ini params
  28. setPhpIniParams();
  29.  
  30. //init config.inc.php file reader
  31. $oConfigFile = new oxConfigFile(OX_BASE_PATH . "config.inc.php");
  32.  
  33. oxRegistry::set("oxConfigFile", $oConfigFile);
  34.  
  35.  
  36. // Basket Details
  37.  
  38. $oSession = oxRegistry::get('oxSession');
  39. $oSession->setForceNewSession();
  40. $oSession->start();
  41.  
  42. $oBasket        = $oSession->getBasket();
  43. $aBasketSummary  = $oBasket->getBasketSummary();
  44.  
  45. print json_encode($aBasketSummary);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement