M
Merrill Higginson
I have an application that navigates through the links in a document,
most of which are "javascript:doThisFunction(args)" type of links.
Using DOM navigation I can find the reference to the javascript
function and store it as a String variable, but is there a way to
execute the function? Currently the only way I know how to do it is
in a series of if/else statements as in:
if (link=="doThisFunction(args)")
doThisFunction(args);
else if (link=="doThatFunction(moreArgs)")
doThatFunction(moreArgs);
... etc.
is there a more elegant way to do this?
Merrill
most of which are "javascript:doThisFunction(args)" type of links.
Using DOM navigation I can find the reference to the javascript
function and store it as a String variable, but is there a way to
execute the function? Currently the only way I know how to do it is
in a series of if/else statements as in:
if (link=="doThisFunction(args)")
doThisFunction(args);
else if (link=="doThatFunction(moreArgs)")
doThatFunction(moreArgs);
... etc.
is there a more elegant way to do this?
Merrill