Jump to content

Recommended Posts

Posted

Boas.

Preciso da vossa ajuda, estou a criar um app android com html5 e javascript, e precisava que o id de um dispositivo movel aparecesse no url na pagina inicial que eu mostro em iframe.

😕

Posted

Estou a fazer uma aplicação android a partir do programa Intel XDK, que utiliza HTML5 e Javascript.

O meu objetivo é utilizar o device.uuid para ir buscar o id do dispositivo que estiver a utilizar e depois enviar esse id para um URL

Posted

Este é oo código que eu tenho:

<!DOCTYPE html>

<html>

<head>

<title>App </title>

<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, minimum-scale=1.0, user-scalable=0, minimal-ui">

<meta name="apple-mobile-web-app-capable" content="yes" />

<META HTTP-EQUIV="Pragma" CONTENT="no-cache">

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

<link rel="stylesheet" type="text/css" href="lib/appframework/icons.css" />

<link rel="stylesheet" type="text/css" href="lib/appframework/af.ui.css" />

<script type="text/javascript" charset="utf-8" src="lib/jquery.min.js"></script>

<script type="text/javascript" charset="utf-8" src="lib/fastclick.min.js"></script>

<script type="text/javascript" charset="utf-8" src="lib/appframework/appframework.ui.min.js"></script>

<script src='cordova.js'></script>

<script>

document.addEventListener("deviceready", onDeviceReady, false);

function onDeviceReady() {

var element = document.getElementById('deviceProperties');

element.innerHTML = '' + device.uuid + '<br />';

}

</script>

</head>

<body>

<div class="view">

<div class="pages">

<div class="panel" id="item1">

<p id="deviceProperties"></p>

<p></p>

<iframe src="https://xxxxx.com/" width ="100%" height="100%"></iframe>

</div>

</div>

</div>

</body>

</html>

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.