Hi again,
I've run into a somewhat strange issue here, which may or may not be by design once again. And since I only have the minified javascript for now, I can't quite figure out why it does what it does.
For reasons relating to phonegap, cordova and some nasty bugs in android 4.0*, I've had to rewrite a lot of code from being nice and proper ( a-tags with href attributes linking to remote views with querystrings ) into storing the querystring variables into localStorage and relying on app.navigate to said remote views.
(* There's an unfortunate bug in the Chromium browser which leads to nice 'file not founds' if accessing files with querystrings when deployed through phone-gap, or through file:/// - URL )
My problem, however:
If I use a normal A tag with href="remote.html" - it inherits or picks up/duplicates header/footer if the data-id matches, which it does.
If I use app.navigate('remote.html') - it doesn't. (Neither if I use document.location = 'remote.html')
In what way does a normal a tag linkage differ from app.navigate? Is there a way to (preferably from one centralized place) enforce/check/reinforce the header/footer?
All my views, regardless of whether they are remote or local share this:
(div data-role="layout" data-id="mobile-view")
Header/footer exists only in index.html. Remote views are simply other instances of a div data-role="layout" data-id="mobile-view".
Manually reloading in browser on such a loaded remote view does redraw the header/footer, worth noting.
Is the easiest way to refrain from using app.navigate?
Are there any implications to using document.location = 'index.html#remote.html' instead? That seems to be the easiest workaround at least.
I've run into a somewhat strange issue here, which may or may not be by design once again. And since I only have the minified javascript for now, I can't quite figure out why it does what it does.
For reasons relating to phonegap, cordova and some nasty bugs in android 4.0*, I've had to rewrite a lot of code from being nice and proper ( a-tags with href attributes linking to remote views with querystrings ) into storing the querystring variables into localStorage and relying on app.navigate to said remote views.
(* There's an unfortunate bug in the Chromium browser which leads to nice 'file not founds' if accessing files with querystrings when deployed through phone-gap, or through file:/// - URL )
My problem, however:
If I use a normal A tag with href="remote.html" - it inherits or picks up/duplicates header/footer if the data-id matches, which it does.
If I use app.navigate('remote.html') - it doesn't. (Neither if I use document.location = 'remote.html')
In what way does a normal a tag linkage differ from app.navigate? Is there a way to (preferably from one centralized place) enforce/check/reinforce the header/footer?
All my views, regardless of whether they are remote or local share this:
(div data-role="layout" data-id="mobile-view")
Header/footer exists only in index.html. Remote views are simply other instances of a div data-role="layout" data-id="mobile-view".
Manually reloading in browser on such a loaded remote view does redraw the header/footer, worth noting.
Is the easiest way to refrain from using app.navigate?
Are there any implications to using document.location = 'index.html#remote.html' instead? That seems to be the easiest workaround at least.