View Complete Thread | FoxWeb Forum Home
Search:
Date:    Msg ID:   
From:    Thread:   
Subject:   
Now is working!
I tested solution 1 and 2, and both work fine. Solution 3 is not available in FoxWeb 1.29c.
I choose the second because the first one put http://myserver.com/main.fwx after I wrote my website address.
 
Thank you very much.
Daniel Diaz
Sent by FoxWeb Support on 11/10/2005 01:37:37 PM:
Here's some information that is specific to FoxWeb 2 and above.  It may work for older versions, but I'm not sure:
 
You can add default.fwx to your list of default documents in the server configuration, but in order for your document to be called, it must be visible to the Web server.  By default, FoxWeb scripts are in a location outside the Web tree, so they are not visible to the Web server.  There are three potential solutions:
 
Solution 1:
Configure your server to automatically redirect to your default script.  You can do this by setting up your virtual directory settings, or by creating a static default document with a redirect META tag.  In our opinion, this is the easiest and most flexible solution.
 
Solution 2:
Place an empty file named default.fwx in the Web tree.  Here's an example:
 
Configuration:
FoxWeb Program Root = D:\FoxWeb\
Web Site Root = D:\inetpub\wwwroot\
Default documents configured for Web site (in this order): main.fwx, default.htm.
 
Let's assume that the path to the real main.fwx is D:\FoxWeb\main.fwx and that you can call it with http://www.myserver.com/main.fwx.  Let's also assume that you also have a file named D:\inetpub\wwwroot\default.htm.  Even though main.fwx is listed prior to default.htm in your list of default documents, the Web server does not "see" mail.fwx, so the URL http://www.myserver.com/ would return the contents of default.htm.
 
Now create an empty file, named main.fwx in D:\inetpub\wwwroot.  Once you do this, the Web server will find main.fwx before default.htm and will call your script.
 
Solution 3:
Place your scripts in the same locations as your static documents and enable the Use Web Server's Directory Mappings option.  Please note that there are security concerns related to this solution.  Read the relevant information in the FoxWeb documentation before going down this road.

FoxWeb Support Team
support@foxweb.com email

Sent by Daniel Diaz on 11/10/2005 12:52:45 PM:
Thanks for this useful tip!
But, how can I put to work a FoxWeb script as default document without specify the script in WebExplorer address bar?
 
Thanks again.
Sent by FoxWeb Support on 11/10/2005 12:13:33 PM:
Are you saying that the information that needs to be returned is static, but you just want to prevent caching?  If this is the case, then using a FoxWeb script will not help.  The way to work around this is to prevent browsers from caching the content.  One way to do this is to insert META tags in the <head> section of main.htm:
 
<meta http-equiv="Expires" content="Sun, 22 Mar 1998 12:00:00 GMT">
<meta http-equiv="Pragma" content="no-cache;>
 

FoxWeb Support Team
support@foxweb.com email

Sent by Daniel Diaz on 11/10/2005 11:54:02 AM:
Oops! I forgot to say that my webserver is working fine!
I had a main.htm page that work well, but, in some case, webexplorers don't refresh the changes that I made on it.
So, I want a FoxWeb script that return always the main.htm content.
I can call my script by name, but if I write only the URL of my site, I see HTTP Error 403.
Of course, IIS had as default document main.fwx
 
So,
main.fwx is the "default document",
http://myserver.com/ not work at all (HTTP Error 403)
 
Thanks in advance
 
Sent by FoxWeb Support on 11/10/2005 10:40:34 AM:
Error 403 Access Denied, means that you do not have rights to the requested URL.  We will need more information in order to help you:
  • Location of Web Root
  • Location of FoxWeb Program Root
  • Location of main.fwx
  • URL that you use to call main.fwx
Also, please try the following and let us know the results:
 
Let's assume that the URL that is failing with a 403 error is  http://myserver.com/.

FoxWeb Support Team
support@foxweb.com email

Sent by Daniel Diaz on 11/09/2005 11:54:12 AM:
Hi, FoxWeb Support
 
I've a little problem:
I setup IIS in order to set 'main.fwx' as default document; but, when I try to access my website, I get HTTP Error 403
 
Thanks in advance.
 
Windows 2000 Server SP4, Visual FoxPro 6 SP5, FoxWeb 1.29c