Blackberry and XUI; problems with x$.html

5 views
Skip to first unread message

Joshua

unread,
Feb 4, 2011, 6:31:12 PM2/4/11
to phonegap
I'm trying to just get started doing some very basic stuff with
Phonegap using XUI, and the simple act of adding a div isn't working
for me. It's entirely possible that I'm missing something obvious,
but I've distilled this down to a very basic page, and it's still not
working (either as a page or within a Phonegap app). I've been using
the 5.0 emulator to do this work, and I get "The page you requested
could not be loaded; it is too large for the device" whenever I try
and add a div to the document. The same code works fine within
Firefox. This is also true of the XUI tests which try to perform the
same task. The page I'm trying to use is below. Is there something
totally obvious I'm missing here? Thanks.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/
TR/html4/strict.dtd">
<html>
<head>
<title>XUI problem</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, minimum-scale=1.0,
maximum-scale=1.0">
<meta name="apple-mobile-web-app-capable" content="yes" />
<script src="javascript/xui_bb_2.0.0.js" type="text/javascript"></
script>

<script type="text/javascript">
x$(window).load(function(e){
x$('#button-add').click(function(){
x$('#header').html('before','<div id="new-div">Hello!</div>');
});
///---
});
</script>
</head>
<body>
<div id="header">
<h1>A header</h1>
<button id="button-add">Click me</button>
</div><!-- /header -->
</body>
</html>

filmaj

unread,
Feb 4, 2011, 8:26:30 PM2/4/11
to phonegap
To confirm: you are trying to run the above code on a BlackBerry 5
simulator, but it isn't working, yes?

If so, can you provide the OS version that the emulator is running
(5.0.0.xxx) and which device it is emulating (8900, 9000, 9650, etc.).

I'll run some tests and try to figure it out. If you post this issue
on the xui issues list (github.com/xui/xui/issues) it will be a
further reminder for me to look into it :)

thanks!

Joshua

unread,
Feb 7, 2011, 11:58:08 AM2/7/11
to phonegap
Thanks for having a look. I'm using the 9550 emulator, running
5.0.0.469. I can try a few other ones as well, and will post to
issues.
Reply all
Reply to author
Forward
0 new messages