jQuery Mobile - javascript : Edit div of the page from the popup
Is it posible to do this ?
I have this HTML code in my index.html:
<body>
<div data-role="content" id="content" data-position="absolute">
<br/><br/>
<table align="center" width="400">
<tr>
<td align="left"><a href="#popup" data-rel="popup"
data-transition="fade"
data-position-to="window"><img
src="../img/location-icon.png" width="36"
id="location" /></a></td>
</tr>
<tr>
<td height="100"><div id="fecha-hora"></div></td>
</tr>
<tr>
<td align="center" height="100"><button
id="btn_marcar" data-inline="true">MARCAR
ASISTENCIA</button></td>
</tr>
<tr>
<td></td>
</tr>
<tr>
<td><div id="estado"></div></td>
</tr>
</table>
</div> <!-- /content -->
<div data-role="popup" id="popup" data-overlay-theme="a" data-theme="a"
data-corners="false" data-tolerance="15,15">
<a href="#" data-rel="back" data-role="button"
data-theme="a" data-icon="delete" data-iconpos="notext"
class="ui-btn-right">Close</a>
<iframe src="main.html" width="480" height="370"
seamless></iframe>
</div>
</body>
My main.html displays good. Here i have some GPS validations for the user
and return and alert . That alert, i need to .html("RESULT") in the div
#estado (on table in index.html).
Here is my main.html:
<script>
function initialize() {
// SOME CODE
if ( .... ) {
alert("HERE U ARE");
$("index.html#estado").html("HERE U ARE");
// IS THIS CORRECT?
}
}
</script>
Thank you for answers..
Sry for bad english, greetings
No comments:
Post a Comment