[Webtest] Re: JavaScripts: Problems with relative path
Marc Guillemot
Marc Guillemot <mguillemot@yahoo.fr>
Mon, 14 Jan 2008 16:07:46 +0100
Hi,
does the problem occur with a recent build (using HtmlUnit 1.14)? Indeed
a problem has been fixed recently concerning urls starting with 2
slashes that wrongly altered the path.
Cheers,
Marc.
--
Blog: http://mguillem.wordpress.com
Willi Kuhnis wrote:
> Hi,
>
> I got a answer, that it could be a error in our application.
> But the Appli runs since years.
>
> the error-message is:
> JavaScript error loading page
> http://10.60.36.59/MyWebAppli/Login.aspx: 404 Not Found for
> http://10.60.36.59/Script/color_functions.js
>
> But it searches the file in a wrong path: http://10.60.36.59/Script/
> the correct path is:
> http://10.60.36.59/MyWebAppli/Script/
>
> In the source. it looks like this:
> <script language="javascript" type="text/javascript"
> src="../Script/color_functions.js"></script>
>
> so who resolves the path wrong ?
>
> Thanks for help
>
> Willi
> ************************************
>
> ****************************
>
> 2008/1/10, Willi Kuhnis <wkuehnis@gmail.com>:
>> Hi,
>>
>> I call the invoke - function with a url like
>> http://10.60.36.59/MyWebAppli/Login.aspx. This works.
>> Then my Application calls something like this:
>> <script language="javascript" type="text/javascript"
>> src="../Script/color_functions.js"></script>
>>
>> Then Webtest gives me this error message:
>> javascript error404 Not Found for http://10.60.36.59/Script/color_functions.js
>>
>> So I think it dont work correctly with "../Script".
>>
>> maybe it also has something to do with host and basepath in <config> ?
>> <config
>> protocol="http"
>> host="10.60.36.59/MyWebAppli"
>> basepath="10.60.36.59/MyWebAppli"
>> port="80"
>> autorefresh="false"
>> showhtmlparseroutput="true"
>> saveresponse="true"
>> resultfile="results.xml"
>> timeout="2000">
>> </config>
>>
>>
>> Or is it a error ?
>> Thanks a lot for help
>>
>>
>> --
>> Willi Kuhnis
>> wkuehnis@gmail.com
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>
>
>