Jump to content

Recommended Posts

Hello everyone, I have a problem with a shopping cart script i downloaded, I dont know how, but every lik in the admin section repeats the url twice, instead of http://localhost/nina/admin/category/, the url that I get is http://localhost/nina/admin/nina/admin/category/ the code of the config file in the shopping cart is // setting up the web root and server root for

// this shopping cart application

$thisFile = str_replace('\\', '/', __FILE__);

$docRoot = $_SERVER['DOCUMENT_ROOT'];

 

$webRoot  = str_replace(array($docRoot, 'library/config.php'), '', $thisFile);

$srvRoot  = str_replace('library/config.php', '', $thisFile);

 

define('WEB_ROOT', $webRoot);

define('SRV_ROOT', $srvRoot);

 

I downloaded the script from here http://www.phpwebcommerce.com/php-mysql-shopping-cart-tutorial.php

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/131656-php-code-problem/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.