Zen Cart Logo
Forums / Installing on a Windows Server / Configure.php + internal network woes :(

Configure.php + internal network woes :(

Locked

Views: 2,987

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
3 Mar 2008, 2:36 AM
#1
johnblaze94 avatar

johnblaze94

New Zenner

Join Date:
Mar 2008
Posts:
10
Plugin Contributions:
0

Configure.php + internal network woes :(

Hey everyone, I am having a major issue that i cant seem to wrap my brain around completely. I have a Static IP, a Windows Server, using WAMP.

In my configure.php files, i have the domains set correctly, so access to my site from the internet works flawlessly. But access from inside the network is bad. All i can get is the main page with no images or formatting. And when i try to access any other zen-cart page on my site, i get directed to the internet gateway login page. I have loaded several other pages into the web folder and accessed them internally and externally, so the problem has to be with a setting in Zen-Cart.

When i change the configure.php files to show the ip of the server, the symptoms reverse. IE: Browsing from inside the network is flawless, and access from the internet dosen't work.

I have tried using the static IP as the domain name in the configure.php, but none of that seems to be working.

Thanks For everyones help in advance!

3 Mar 2008, 6:51 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Configure.php + internal network woes :(

Please list:

  • public domain name
  • the public static IP address
  • your HTTP_SERVER setting in your configure.php file
  • your DIR_WS_CATALOG setting in your configure.php file
  • the URL you're using on your internal network PCs to access the server
  • the first 40 lines from browser source when viewing the page from your internal network (mainly looking for the BASE HREF and the stylesheet link tags)
3 Mar 2008, 3:09 PM
#3
johnblaze94 avatar

johnblaze94

New Zenner

Join Date:
Mar 2008
Posts:
10
Plugin Contributions:
0

Re: Configure.php + internal network woes :(

datareflects.biz

75.148.185.126

'www.datareflects.biz'

'localhost'

I have tried going through datareflects.biz, and it takes me directly to the gateway login screen. If i try to access the server through one of its nic's IP addresses, it gives me a flawed homepage.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en"> <head> <title>DataReflects Computers, Printers, Printer Parts, and More!</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <meta name="keywords" content="Printers Networking Controllers Terminals Tape Drives Communication printer, printer parts, okidata, memorex, telex, line printer repair, dot matrix printer repair " /> <meta name="description" content="DataReflects Computers : - Printers Networking Controllers Terminals Tape Drives Communication printer, printer parts, okidata, memorex, telex, line printer repair, dot matrix printer repair" /> <meta http-equiv="imagetoolbar" content="no" /> <meta name="author" content="The Zen Cart™ Team and others" /> <meta name="generator" content="shopping cart program by Zen Cart™, <http://www.zen-cart.com> eCommerce" /> <base href="http://www.datareflects.biz/" /> <link rel="stylesheet" type="text/css" href="includes/templates/classic/css/stylesheet.css" /> <link rel="stylesheet" type="text/css" href="includes/templates/classic/css/stylesheet_css_buttons.css" /> <link rel="stylesheet" type="text/css" media="print" href="includes/templates/classic/css/print_stylesheet.css" /> </head> <body id="indexHomeBody"> <div id="mainWrapper"> <!--bof-header logo and navigation display--> <div id="headerWrapper"> <!--bof-navigation display--> <div id="navMainWrapper"> <div id="navMain"> <ul class="back"> <li><a href="http://www.datareflects.biz/">Home</a></li>
<li><a href="http://www.datareflects.biz/index.php?main_page=login&zenid=kv4lhu4lsqjv4t12019a0h8v62">Log In</a></li>
</ul> </div> <div id="navMainSearch"><form name="quick_find_header" action="http://www.datareflects.biz/index.php?main_page=advanced_search_result" method="get"><input type="hidden" name="main_page" value="advanced_search_result" /><input type="hidden" name="search_in_description" value="1" /><input type="hidden" name="zenid" value="kv4lhu4lsqjv4t12019a0h8v62" /><input type="text" name="keyword" size="6" maxlength="30" style="width: 100px" value="Enter search keywords here" onfocus="if (this.value == 'Enter search keywords here') this.value = '';" onblur="if (this.value == '') this.value = 'Enter search keywords here';" /> <input type="submit" value="Search" style="width: 45px" /></form></div> <br class="clearBoth" /> </div> <!--eof-navigation display-->
3 Mar 2008, 7:31 PM
#4
johnblaze94 avatar

johnblaze94

New Zenner

Join Date:
Mar 2008
Posts:
10
Plugin Contributions:
0

Re: Configure.php + internal network woes :(

Here is a copy of my configure.php from the /www/includes folder
// Define the webserver and path parameters
// HTTP_SERVER is your Main webserver: eg-http://www.your_domain.com
// HTTPS_SERVER is your Secure webserver: eg-https://www.your_domain.com
define('HTTP_SERVER', 'http://10.1.10.175');
define('HTTPS_SERVER', 'https://10.1.10.175');

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

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!
// * DIR_WS_* = Webserver directories (virtual/URL)
// these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
define('DIR_WS_CATALOG', '/');
define('DIR_WS_HTTPS_CATALOG', '/');

define('DIR_WS_IMAGES', 'images/');
define('DIR_WS_INCLUDES', 'includes/');
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', DIR_WS_CATALOG . 'pub/');
define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/');

define('DIR_WS_PHPBB', '/');

// * DIR_FS_* = Filesystem directories (local/physical)
//the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
define('DIR_FS_CATALOG', 'C:/wamp/www/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/');
define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS);
define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');

With these settings, i can view the website from instde my network, but not from outside.

3 Mar 2008, 7:35 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Configure.php + internal network woes :(

  1. On each of the computers on your internal network, add the following to your "hosts" file:
10.1.10.175  datareflects.biz www.datareflects.biz
  1. Then make sure your configure.php files say www.datareflects.biz

  2. Then use www.datareflects.biz to access your server from your internal PCs.

Depending on your operating system, your "hosts" file is typically located at c:\windows\system32\drivers\etc\hosts
Note that the file has NO extension on it. So, when you edit it, make sure you save it with NO extension. (ie: notepad often adds .txt)

3 Mar 2008, 7:56 PM
#6
johnblaze94 avatar

johnblaze94

New Zenner

Join Date:
Mar 2008
Posts:
10
Plugin Contributions:
0

Re: Configure.php + internal network woes :(

Thanks so much for your help. I cant believe the Hosts file slipped my mind like that....

Sometimes im dumb...

Works like a charm now.