I'm gradually getting a handle on the whole jQM paradigm, but there are still some things that I haven't figured out. I'm hoping that someone can help me...
1) jQuery Mobile loads subsequent pages via Ajax. But what should those subsequent pages look like? Full web pages with a head, etc? Or just the <body> contents?
2) If ajax-loaded pages should be HTML fragments rather than entire documents, are there any request params that jQM sends, or can I somehow specify these parameters so that I can know to decorate pages differently depending on whether jQM is requesting them?
3) Is there any way to access the jQM-returned HTML before jQM turns it into virtual pages?
Thanks in advance for any help you can offer.
(I haven't found any really detailed documentation on how Ajax loading happens. If there is a write-up on what's happening *in detail*, I'd love a pointer.)
I have some data that (for complex reasons) is only available to the decorator that wraps around the <body> tag. I'm currently adding that to the <body> tag as a data attribute.
I need to copy that data to the individual page divs, and I can't figure out the best way to do that. One thought was to intercept the AJAX load before page div(s) are extracted, and manipulate the DOM to copy the data attribute from the <body> to the page divs.
Is this possible? Can anyone suggest the best way to do this?
I wish to use jQuery Autocomplete to show matching items from a static list of items. My designer wants to only show a maximum of 10 items, however. What's the best way to limit the maximum number of items that can be shown in the pop-up list?
I know that I can use jQueryObj.trigger('keypress') to simulate a key press event, but how can I populate the keypress event attributes? I am testing an autocomplete plugin which of course requires simulating keystrokes.
I noticed the asserts 'deepEqual', 'notEqual', etc. aren't documented in the QUnit docs. Is this an oversight or am I missing something? Can I safely use these asserts, or are they subject to change?
When we switched from jQuery 1.4.1 to the new version, one of our forms started throwing an exception on all versions of IE. The error details are below.
The form in question has an 'onsubmit' handler that causes a two-phase submit. You can see what it does by going to http://www.glassdoor.com/Salaries/index.htm and typing 'fargo' in the 'location' field in the top green search bar. This causes a location disambiguation to occur, and if there are multiple choices, a popup appears. Clicking on one of the choices fills in some form fields and then submits the form, throwing an exception on IE. If you move past the exception, the form submits correctly.
What changes that would affect this?
Ron
----------
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.2; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
Timestamp: Tue, 27 Apr 2010 00:07:15 UTC
Message: Object doesn't support this property or method
When I create a modeless dialog, my page becomes taller. This is very annoying, as my page decorations normally extend to the bottom of the page, but when a dialog is created, a large blank space appears.