[prev in list] [next in list] [prev in thread] [next in thread]
List: kfm-devel
Subject: Using KHTMLPart to evaluate/follow javascript links from code .
From: Martin L <nitram () lutken ! dk>
Date: 2008-01-13 20:10:59
Message-ID: 478A7053.9050406 () lutken ! dk
[Download RAW message or body]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi<br>
<br>
I want to have KHTMLPart get me all links on one page, which I think I
have managed now.<br>
Only problem is that some links needs a javascript to be evaluated like
when the source fx uses code like this:<br>
<font face="monospace"><b><span class="tabActive"><a href="#"
OnMouseOver="linkTab('','index','INDEX_DESCRIPTION',this)"
class="tabLinkActive">Description</a></span></b></font><br>
<br>
I have the Node, and the string '<font \
face="monospace"><b>linkTab('','index','INDEX_DESCRIPTION',this)</b></font>'
. How do I get the result of this function<br>
without actually moving the mouse ?<br>
I have tried to use the <br>
KJS::Interpreter pJS ( = m_pBrowser->jScriptInterpreter() );<br>
And calling pJS->evaluate( na.nodeValue().string() ); <br>
<br>
But I get "UndefinedType" from the KJS::Completion return type.<br>
<br>
-Martin Lütken<br>
<br>
</body>
</html>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic