brewbeer Posted July 30, 2005 Share Posted July 30, 2005 I have set up a development site locally to test my oscommerce changes. I am using apache 1.3 and oscommerce with apache running virtual hosts and the local hosts file in windows. As far as I can tell, the configuration is set up appropriately. It find the index or a hard url to a page, but the tep_href_links add an extra domain name. for example. http://[local_domain_name]/[local_domain_name]/login.php If it is a straight link like [file_name.php] it works. I have also echoed the result of the tep_href_link and it does not have the duplicate. I have found this a very strange issue. Probably nothing to do with osCommerce, but only occurs when I use tep_href_link... and hosts file. I may use a Local DNS server but hosts are less intensive. Anyone else had this complication? Thanks in advance "Chooca ma blah blah" Link to comment Share on other sites More sharing options...
Guest Posted July 30, 2005 Share Posted July 30, 2005 post your configure.php usually in there Link to comment Share on other sites More sharing options...
brewbeer Posted July 30, 2005 Author Share Posted July 30, 2005 post your configure.php usually in there <{POST_SNAPBACK}> <?php define('HTTP_SERVER', 'xxx_local.com'); //this is a changed name for security 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', 'localhost'); define('HTTPS_COOKIE_DOMAIN', ''); define('HTTP_COOKIE_PATH', '/'); define('HTTPS_COOKIE_PATH', ''); define('DIR_WS_HTTP_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', 'c:/intranet/oscommerce/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); // define our database connection define('DB_SERVER', 'localhost'); // eg, localhost - should not be empty for productive servers define('DB_SERVER_USERNAME', 'xxxxx'); define('DB_SERVER_PASSWORD', 'xxxxx'); define('DB_DATABASE', 'xxxxx'); define('USE_PCONNECT', 'false'); // use persistent connections? define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql' ?> I can't seem to find an issue with oscommerce. It seems apache conf and hosts files prepend the resolved host name only when using tep_href_link. I figure somebody has set windows hosts to use apache virtual server with an oscommerce install. I have done the localhost and intranet setups before but I that is with a local DC DNS Server. Weird stuff and I have been looking all over apache and any site that has info. By default, the local domain name is found and resolved and the site has all images and such but the wrong href. -Mark "Chooca ma blah blah" Link to comment Share on other sites More sharing options...
Guest Posted July 30, 2005 Share Posted July 30, 2005 you should be using http://localhost for the domain, however it is all dependent upon how you have apache configured, etc Link to comment Share on other sites More sharing options...
brewbeer Posted July 30, 2005 Author Share Posted July 30, 2005 you should be using http://localhost for the domain, however it is all dependent upon how you have apache configured, etc <{POST_SNAPBACK}> strange thing. I commented the line in the function tep_href_link. it reads if ($connection == 'NONSSL') { //$link = HTTP_SERVER . DIR_WS_HTTP_CATALOG; } now it only has one domain name, correcting the link. so it seems apache is automatically adding the domain name. I will try putting in localhost. "Chooca ma blah blah" Link to comment Share on other sites More sharing options...
Guest Posted July 30, 2005 Share Posted July 30, 2005 you dont need to edit anything filewise, just your configure.php files and have your php.ini file setup properly for where your web files are located. Link to comment Share on other sites More sharing options...
brewbeer Posted July 30, 2005 Author Share Posted July 30, 2005 Man, thanks alot! You got my wheels turning. It wasn't the localhost, I HAD to have http://domainname.com instead of domainname.com . Put one and one equal you get one. I suppose when using windows hosts and apache it has a identity check of the name if i matches it uses just one if it is different it doesn't match and makes two. Awesome! "Chooca ma blah blah" Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.