klmiop Posted July 9, 2014 Share Posted July 9, 2014 Hi I'm trying to include a Prestashop class outside of my shop installation. Let's say i have my root folder called site, inside i have prestashop installed in a shop folder, and i have a standard website next to it. So i have : /root/site/a.php/root/site/b.php (thoses pages are for a standard website)and /root/site/shop/ where prestashop is installed. I'm trying to use Prestashop's Product class inside my standart website. I created a test.php script containing this : include_once('config/config.inc.php'); include_once('config/settings.inc.php'); $product = new Product(5); var_dump($product); I saved this file here : /root/site/shop/test.php, so it's at the root folder of prestashop, and when i call it, everything works fine, the dump prints all the data informations about the product with the id 5; So i tried to include this test.php in a page on my standard site, here : /root/site/test2.php Inside i'm just including the first script i made : include_once('shop/test.php'); But actually, when i go to /root/site/test2.php, i'm getting redirected to /root/site/shop If someone has any information that could help me to solve this, that would be great. Thanks for taking the time to read this, Best regards. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now