Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

configure.php - not creating urls correctly


DataMouse

Recommended Posts

Posted

Hi all

 

I have had some issues with my configure.php files (both admin/includes and the other one).

I've managed to fix both files to a degree by fixing the catalog/includes/configure.php values for database, logins etc then copying this file to admin/includes/configure.php.

 

I can now access my admin panel, but the urls are missing "/" from them.

 

For example, If I click on "catalog" in the admin front screen, I get this URL:

http://www.datamouse.bizdir_ws_admincatego...f2e9091d52bd022

 

This should be closer to:

http://www.datamouse.biz/catalog/admin/categories.php

 

(there is also an error on this page that: Error Error: Catalog images directory does not exist: DIR_FS_CATALOG_IMAGES)

 

It's clear that the variable from DIR_FS are not set correctly.

 

Can anyone walk me through manually changing these in my configure.php file, please?

 

I know I could reinstall - but I've made masses of changes and don't want to have to go through them again.

 

Thanks guys

 

 

Danny

Posted
Hi all

 

I have had some issues with my configure.php files (both admin/includes and the other one).

I've managed to fix both files to a degree by fixing the catalog/includes/configure.php values for database, logins etc then copying this file to admin/includes/configure.php.

 

I can now access my admin panel, but the urls are missing "/" from them.

 

For example, If I click on "catalog" in the admin front screen, I get this URL:

http://www.datamouse.bizdir_ws_admincatego...f2e9091d52bd022

 

This should be closer to:

http://www.datamouse.biz/catalog/admin/categories.php

 

(there is also an error on this page that: Error Error: Catalog images directory does not exist: DIR_FS_CATALOG_IMAGES)

 

It's clear that the variable from DIR_FS are not set correctly.

 

Can anyone walk me through manually changing these in my configure.php file, please?

 

I know I could reinstall - but I've made masses of changes and don't want to have to go through them again.

 

Thanks guys

Danny

Look here: http://www.oscommerce.com/forums/index.php?sho...=193738&hl=

Posted

 

Thanks - but that's not the issue (I've already read that cover to cover!)

 

The two files are different and refer to difference variables.

Somehow, the value is not being passed to the variables correctly. This is the bit that I need help sorting.

 

Can anyone help, please?

 

DM

Posted
Thanks - but that's not the issue (I've already read that cover to cover!)

 

The two files are different and refer to difference variables.

Somehow, the value is not being passed to the variables correctly. This is the bit that I need help sorting.

 

Can anyone help, please?

 

DM

Well post the two files without the sensitive database info.

Also check if you have an includes/local directory.

Posted
Well post the two files without the sensitive database info.

Also check if you have an includes/local directory.

 

Thanks

 

This is the catalog/includes/configure.php file contents:

 

define('HTTP_SERVER', 'http://www.datamouse.biz'); // eg, http://localhost - should not be empty for productive servers

define('HTTPS_SERVER', ''); // eg, https://localhost - should not be empty for productive servers

define('ENABLE_SSL', false); // secure webserver for checkout procedure?

define('HTTP_COOKIE_DOMAIN', 'www.datamouse.biz');

define('HTTPS_COOKIE_DOMAIN', '');

define('HTTP_COOKIE_PATH', '/catalog/');

define('HTTPS_COOKIE_PATH', '');

define('DIR_WS_HTTP_CATALOG', '/catalog/');

define('DIR_WS_HTTPS_CATALOG', '');

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');

define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');

define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');

define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/kunden/homepages/1/d163279975/htdocs/catalog/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

 

This is my catalog/admin/includes.configure.php:

 

define('HTTP_SERVER', 'http://www.datamouse.biz'); // eg, http://localhost - should not be empty for productive servers

define('HTTPS_SERVER', ''); // eg, https://localhost - should not be empty for productive servers

define('ENABLE_SSL', false); // secure webserver for checkout procedure?

define('HTTP_COOKIE_DOMAIN', 'www.datamouse.biz');

define('HTTPS_COOKIE_DOMAIN', '');

define('HTTP_COOKIE_PATH', '/catalog/');

define('HTTPS_COOKIE_PATH', '');

define('DIR_WS_HTTP_CATALOG', '/catalog/');

define('DIR_WS_HTTPS_CATALOG', '');

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');

define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');

define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');

define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');

define('DIR_FS_CATALOG', '/kunden/homepages/1/d163279975/htdocs/catalog/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

 

The issue seems to be with DIR_WS_ADMIN - but I can't see it in here...

 

Thanks :thumbsup:

Posted

define('DIR_WS_ADMIN', '/catalog/admin/');
define('DIR_WS_CATALOG', '/catalog/');
define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

 

Those 3 look like they will solve most of your problems

Posted
Also check if you have an includes/local directory.

I do - but only in catalog/includes/local.

It gives email info like this:

<?php

 

/******************************************************

* Email Invoice 1.0.

* The values below are required by the email invoice mod.

* Author Contact: [email protected]

******************************************************/

 

/**** Email Invoice File Definitions ****/

define('FILENAME_EMAIL_INVOICE', 'email_invoice.php');

define('FILENAME_EMAIL_CACHE_FILE', 'temp_cache.php');

define('FILENAME_ORDERS_INVOICE', 'invoice.php');

 

/**** Email Directory Definitions ****/

define('DIR_FS_ADMIN', 'C:/apache/blah blah/catalog/admin/'); // absolute path required

define('EMAIL_INVOICE_DIR', 'email_invoice/');

 

/*** End of Mod ***/

 

?>

 

I tried altering to my address (http://www.datamouse.biz/catalog/admin/) but no joy.

Posted

No having seen your post above mine it looks like a very old set of configure.php files, yet your admin section is looking for newer configure.php files e.g.

 

http://www.datamouse.bizdir_ws_admincatego...

Posted
define('DIR_WS_ADMIN', '/catalog/admin/');
define('DIR_WS_CATALOG', '/catalog/');
define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

 

Those 3 look like they will solve most of your problems

 

Do I add these to the catalog/includes/configure.php - or the admin/includes/configure.php?

Posted
Do I add these to the catalog/includes/configure.php - or the admin/includes/configure.php?

 

 

It looks to me like a hotchpotch of files I think you'd be better off with a fresh RC1.

Posted
It looks to me like a hotchpotch of files I think you'd be better off with a fresh RC1.

 

RC1?

Is that a reinstall?

My first choice would be to change the files or variables.

 

Reinstalling would mean losing all of my changes (and I've made hundreds), and all of my products are for download (over 10gb of them).

Posted
RC1?

Is that a reinstall?

My first choice would be to change the files or variables.

 

Reinstalling would mean losing all of my changes (and I've made hundreds), and all of my products are for download (over 10gb of them).

 

 

Well if your oscommerce files are as old as those configure.php files look you may well have a highly insecure oscommerce installation.

 

I understand you don't like the idea of a fresh install but long term I have to say I see it as the best option.

 

Sorry.

Posted
Well if your oscommerce files are as old as those configure.php files look you may well have a highly insecure oscommerce installation.

 

I understand you don't like the idea of a fresh install but long term I have to say I see it as the best option.

 

Sorry.

 

Arse...

I'm running v2.2. What's the newest?

Posted
Arse...

I'm running v2.2. What's the newest?

 

 

Those configure.php files aren't MS2.2

Posted
Those configure.php files aren't MS2.2

 

I've just downloaded the 2.2rc1 zip file and had a look at the admin/includes/configure.php file.

It says this:

$Id: configure.php,v 1.14 2003/02/21 16:55:24 dgw_ Exp $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2002 osCommerce

 

Released under the GNU General Public License

*/

 

// define our webserver variables

// FS = Filesystem (physical)

// WS = Webserver (virtual)

define('HTTP_SERVER', ''); // eg, http://localhost or - https://localhost should not be NULL for productive servers

define('HTTP_CATALOG_SERVER', '');

define('HTTPS_CATALOG_SERVER', '');

 

 

Exactly the same as mine.

 

:blink:

Posted

Try this as the catalog/admin/includes/configure.php adding your DB info ofc

 

<?php
/*
 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
 define('HTTP_SERVER', 'http://www.datamouse.biz'); // eg, http://localhost - should not be empty for productive servers
 define('HTTP_CATALOG_SERVER', '');
 define('HTTPS_CATALOG_SERVER', '');
 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module
 define('DIR_FS_DOCUMENT_ROOT', '/kunden/homepages/1/d163279975/htdocs/catalog/'); // where the pages are located on the server
 define('DIR_WS_ADMIN', '/admin/'); // absolute path required
 define('DIR_FS_ADMIN', '/kunden/homepages/1/d163279975/htdocs/catalog/admin/'); // absolute pate required
 define('DIR_WS_CATALOG', '/catalog/'); // absolute path required
 define('DIR_FS_CATALOG', '/kunden/homepages/1/d163279975/htdocs/catalog/'); // absolute path required
 define('DIR_WS_IMAGES', 'images/');
 define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
 define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
 define('DIR_WS_INCLUDES', 'includes/');
 define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
 define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
 define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
 define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
 define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
 define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
 define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
 define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

// define our database connection
 define('DB_SERVER', ''); // eg, localhost - should not be empty for productive servers
 define('DB_SERVER_USERNAME', '');
 define('DB_SERVER_PASSWORD', '');
 define('DB_DATABASE', '');
 define('USE_PCONNECT', ''); // use persisstent connections?
 define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'
?>

Posted

edited the above changing

 

define('DIR_WS_CATALOG', '/catalog/');

Posted

Better!

The URL did point to:

 

www.datamouse.bizVARIABLEfilelocations

 

Now the url points to www.datamouse.biz/admin/filelocations

 

It just needs to point to

 

www.datamouse.biz/CATALOG/admin/filelocations

 

Thanks

Posted

I think I got it:

 

define('DIR_WS_ADMIN', '/catalog/admin/'); // absolute path required

 

Just to check, will this cock anything else up...? Have I done it right? (cos now my images aren't showing in teh admin screens for products)

 

DM

Posted
Better!

The URL did point to:

 

www.datamouse.bizVARIABLEfilelocations

 

Now the url points to www.datamouse.biz/admin/filelocations

 

It just needs to point to

 

www.datamouse.biz/CATALOG/admin/filelocations

 

Thanks

 

See the small change I made.

Posted
I think I got it:

 

define('DIR_WS_ADMIN', '/catalog/admin/'); // absolute path required

 

Just to check, will this cock anything else up...? Have I done it right? (cos now my images aren't showing in teh admin screens for products)

 

DM

 

 

No recopy the file I gave you there is a small change in it

Posted

There are better options than Email Invoice, but I do not see how this would be in configure.php.

Posted
See the small change I made.

 

I didn't... Looking now.

 

I changed this line:

define('DIR_WS_CATALOG', ''); // absolute path required

 

to

define('DIR_WS_CATALOG', 'http://www.datamouse.biz/catalog/'); // absolute path required

 

and it seems to work...

Posted
There are better options than Email Invoice, but I do not see how this would be in configure.php.

 

Sorry - I'm not understanding.

What should be in configure (the local one) and what are the better options?

 

All of these issues came about because I was trying to use aHTML template to send mails.

Some of my files have been changed and then my hard drive gave up the ghost, losing all of my copies :blush:

Posted

Firstly please try the catalog/admin/includes/configure.php that I gave above (adding db info).

 

and tell me if your admin end now works please.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...