[webkit-qt] How does QtWebkit parse this web page?

naixuan guan guannaixuan at gmail.com
Mon Jan 11 22:54:20 PST 2010


yes, I try qwebframe::evaluateJavaScript(). But after test, I
found something...

First by reading some docs I know the follow page will call a activeX
plugin.

I rewrite the webpage as follow:

<OBJECT id=StormPlayer style="LEFT: 0px; WIDTH: 100%; TOP: 0px; HEIGHT:
100%"
codeBase=http://123.123.123.181:8080/storm.cab#version=3,8,9,7 height=400
width=800 classid=clsid:BDBB259C-9729-484F-BF9D-778149B375B2>
<PARAM NAME="URL" VALUE="?">
<PARAM NAME="ShowUI" VALUE="1">
<PARAM NAME="volume" VALUE="90">
<PARAM NAME="autoPlay" VALUE="2">
<PARAM NAME="mute" VALUE="0">
<PARAM NAME="DropEnable" VALUE="0">
<PARAM NAME="EnableFullScreen" VALUE="0">
<PARAM NAME="ShowVideo" VALUE="1">
<PARAM NAME="loop" VALUE="2">
</OBJECT>
<SCRIPT language=JavaScript>
alert(document.StormPlayer.URL); //only change this argument
</SCRIPT>
when I use arora(based on QtWebkit) load this page, it alert "undefined".
when I use firefox or IE(not install the activeX plugin), it also alert
"undefined".
when I use IE(with this activeX plugin installed), it alert "?".

so I guess, unless we install this activeX plugin, the browser
will not recognize the param "URL" in this "object" tag, of course we can't
change its value through JS.
By the way, activeX work only on Windows, Is there any way that webkit in
Qt/E could parse this page? or can we rewrite this webpage then we can parse
the url set by JS(because I want to build a player plugin and get the video
data through the url)

Hope anyone give me some tips.

Thanks!

gnx
2010/1/9 tonikitoo (Antonio Gomes) <tonikitoo at gmail.com>

> same results w/ qwebframe::evaluateJavaScript() ?
>
> On Thu, Jan 7, 2010 at 9:34 PM, naixuan guan <guannaixuan at gmail.com>
> wrote:
> > Hello, everyone!
> > I met a web page as follow:
> > <OBJECT id=StormPlayer style="LEFT: 0px; WIDTH: 100%; TOP: 0px; HEIGHT:
> > 100%"
> > codeBase=http://123.123.123.181:8080/storm.cab#version=3,8,9,7height=400
> > width=800 classid=clsid:BDBB259C-9729-484F-BF9D-778149B375B2>
> > <PARAM NAME="URL" VALUE="?">
> > <PARAM NAME="ShowUI" VALUE="1">
> > <PARAM NAME="volume" VALUE="90">
> > <PARAM NAME="autoPlay" VALUE="2">
> > <PARAM NAME="mute" VALUE="0">
> > <PARAM NAME="DropEnable" VALUE="0">
> > <PARAM NAME="EnableFullScreen" VALUE="0">
> > <PARAM NAME="ShowVideo" VALUE="1">
> > <PARAM NAME="loop" VALUE="2">
> > </OBJECT>
> > <SCRIPT language=JavaScript>
> > document.StormPlayer.URL = "abc.def.sds";
> > </SCRIPT>
> >
> > now I have create a "Qt based plugin"(based on QWebPluginFactory) for
> this
> > "object" tag, but my plugin
> > could only get the value of "URL" is "?" in the MyPlugin::create()
> function.
> > How could I get the url modified by JS in my plugin?
> > Any suggestion will be appreciate~
> > Thanks!
> >
> > gnx
> > _______________________________________________
> > webkit-qt mailing list
> > webkit-qt at lists.webkit.org
> > http://lists.webkit.org/mailman/listinfo.cgi/webkit-qt
> >
> >
>
>
>
> --
> --Antonio Gomes
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-qt/attachments/20100112/6e084537/attachment.html>


More information about the webkit-qt mailing list