×
Namespaces

Variants
Actions
Revision as of 02:56, 13 April 2011 by hamishwillee (Talk | contribs)

S60 Widgets and iframes

From Nokia Developer Wiki
Jump to: navigation, search


Compatibility: Web Runtime in S60 3rd Edition, Feature Pack 2

IFraming

As such iframes is not optimal solution since it's very heavyweight operation, in practice all iframes are executed as separate browser windows. Therefore it is not promoted to used iframes in Widget context since iframes can have big impact to memory consumption and overall performance Widget. You should also notice that S60 iframes does not support scrolling in Widget or Browser mode.

Example

iframes work only if they refer to a html page.

<iframe width="50" height="50" name="frm" id="frm"
marginwidth="0" marginheight="0" src="test.html"></iframe>
 
In test.html you can utilize any HTML techniques you prefer.
 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<link rel="stylesheet" type="text/css" href="iframing.css"/>
</head>
<body>
<img src="inbox.png"/>
</body>
</html>

Wrong way to utilize iframes is to refer something else than html page.

<!--this code will not work in real devices-->
<iframe width="50" height="50" name="notworking" marginwidth="0"
marginheight="0" src="kala.png"></iframe>
<!--this code will not work in real devices-->
52 page views in the last 30 days.