getTimeDiff and getDate(String) are not supported.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Anonymous
-
2003-05-07
getTimeDiff and getDate are defined in the parent inside a JavaScript file. So is there any other supported way of calling functions in the parent page?
Thanx
richard
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I am getting a ScriptException for the following script block. The message I get is TypeError : undefined is not a function. {httpunit; }
<script language="JavaScript1.2">
parent.getTimeDiff(); parent.getDate("Rendering query list");
var reloadUrl = location.href;
var postData = "O=1&Form=doquery.jsp&s=server.com&S=HPD%3aHelpDesk&Qual=%27Login+Name%2b%27%3d$USER$+AND+%27Status%27%3c%22Resolved%22&U=user&Pw=pw&S=HPD%3AHelpDesk&Qual=%27Login+Name%2B%27%3D%24USER%24+AND+%27Status%27%3C%22Resolved%22&O=1&Pw=pw&Form=doquery.jsp&s=server.com&U=user&";
var searchString = location.search;
var searchStringLength = searchString.length;
if ( searchStringLength > 0 )
{
searchString = searchString.substring(1);
}
var searchIndex = postData.indexOf(searchString);
if ( searchIndex == 0 )
{
postData = postData.substring(searchStringLength);
}
if ( (reloadUrl.charAt(reloadUrl.length-1) != '&') && (postData.charAt(0) != '&') )
{
reloadUrl += "&";
}
reloadUrl += postData;
</script>
It is the second script block and there is another script block after it.
I have tested with the version 1.5.3 and 1.5.4-d-05May.
Thanx
richard
It seems to that there might be some problem with the handling of the parent object. When I comment the first line the problem seems to go away.
Does anybody know how HttpUnit handles the parent object?
Thanx
richard
getTimeDiff and getDate(String) are not supported.
getTimeDiff and getDate are defined in the parent inside a JavaScript file. So is there any other supported way of calling functions in the parent page?
Thanx
richard