Skip to content

Instantly share code, notes, and snippets.

@macdonst macdonst/index.html Secret
Created May 26, 2011

What would you like to do?
Example of how to use the ChildBrowser in Android
<!DOCTYPE html >
<html lang="en">
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=no" />
<meta name="format-detection" content="telephone=yes" />
<title>Test App</title>
<script type="text/javascript" charset="utf-8" src="phonegap.0.9.5.js"></script>
<script type="text/javascript" charset="utf-8" src="childbrowser.js"></script>
<script language="text/javascript" type="text/javascript">
* Called when initial web page is loaded
function onBodyLoad()
// Listen for PhoneGap framework to finish init
* When this function is called, PhoneGap has been initialized and is ready to roll
function onDeviceReady() {
<body onload="onBodyLoad();">
<a href="#" onclick="window.plugins.childBrowser.showWebPage('');">Open in child browser</a>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.