I just noticed that the data-direction="reverse" gets a hiccup after a while?
I have made an example where I with little jquery magic, just adds the attribute "data-direction" to all anchors that have less index value than the active page, this because I would like to have transitions in the correct direction. But if you click around for a while, back and forward then the function get a hiccup and the transition effect goes the opposite direction?
I use two rows of simple jquery code to change the attribute, so I can't see the problem with those.
I can't figure out how to get the width() of block elements, especially if they have "width: auto" in the CSS?
We are talking about block elements that dynamically resizes depending on the screen size and these normally do return a value if I use the standard "document ready" function for browsers, but as I understand it I should use pagebeforecreate, pagecreate, pageshow or any of the other page events available.
this is the simple code I am using:
.my div {
width: auto;
}
$('[data-role=page]').live('pageshow', function (event, ui) {
var width = $('.my div').width();
});
I have tried everything and jquery continues to return a blank value?
I have disabled the back button by using the below script, which works great and I made my own button with my own style, but jquery seems to add extra html into my button, in this case two extra SPAN element.
My button has now three SPAN element, including the two jquery added which of course makes the button horrible, so is there any way to prevent this from happen? Or is there anyway to override the script that outputs the default back button?
It seems like jquery are adding extra html into both of the buttons in the header, i.e. the left button and as well the right button?