View Complete Thread | FoxWeb Forum Home
Search:
Date:    Msg ID:   
From:    Thread:   
Subject:   
You did not provide us with the location of your Web root, FoxWeb Program Root, directory where the images are located and directory where your scripts are located in each example.  This makes it harder to be certain of the problem, but I will try.
 
I assume that your script code remains the same in both examples.  The code uses "/picts/mbm_zipcodes.jpg" for the image source, which means that your images must reside in the picts sub-folder of your web root.  In order for both scenarios to work, the scripts must remain in that location.  Even if you move your script ourside the web tree, the images must remain there.

FoxWeb Support Team
support@foxweb.com email

Sent by John Sullivan on 08/20/2006 05:45:06 PM:
I am trying to get scripts located outside the web tree to work properly. The scripts run  but do not produce the expected browser output unless I place them in the web tree and then change the Foxweb  Control Center to reflect Use Web Server's Directory Mappings. Specifically, the image is outputted correctly when using script located in the web tree but not outputted when located outside the web tree.

I have read the Locating and Addressing Scripts many times but obviously I am missing something. Perhaps the following information will enable you to point me in the right direction.

Here is the setup. I used a simple Foxweb script and called it Zip_Test.Fwx. The script looks like this:

*** Foxweb Zip_Test.FWX TEST script*********************

<%
** The testinfo is outputted so I know I am in the correct script
TestInfo = "this is test #5"
%>
<html><head>
<title>Zipcode Search Page</title>
</head>
<body>
<img src="/picts/mbm_zipcodes.jpg" width="100%" Height="150">
<%=TestInfo%>
</BODY>
</HTML>

FIRST TEST - INSIDE WEB TREE - THIS WORKS

Using the “Use Web Server's Directory Mappings” in the Foxweb Control Center and with the script located in the web tree, the following URL works.

http://localhost/Marketing4insurance/ZIP_test.FWX    (this works)

Storing the Foxweb script in the web tree allows the graphic to display as expected.

NEXT TEST - OUTSIDE WEB TREE - THIS DOES NOT WORK

With  the “Use Web Server's Directory Mappings” UNCHECKED in the Foxweb Control Center, and placing the script in the directory specified in the Foxweb Control Center, the following URL DOES NOT WORK.

http://localhost/ZIP_test.FWX (This does not work – I reload the browser each time with a different test number to ensure the script recompiled and ran.)

I tried a variety of options for relative addressing and none works. These are:
 
<img src="\picts\mbm_zipcodes.jpg" width="100%" Height="150">
<img src="picts\mbm_zipcodes.jpg" width="100%" Height="150">
<img src=".\picts\mbm_zipcodes.jpg" width="100%" Height="150">
<img src="..\picts\mbm_zipcodes.jpg" width="100%" Height="150">
<img src="/picts/mbm_zipcodes.jpg" width="100%" Height="150">
<img src="picts/mbm_zipcodes.jpg" width="100%" Height="150">
<iimg src="../picts/mbm_zipcodes.jpg" width="100%" Height="150">
 
Do you have any suggestions on what to try next?

John Sullivan