开发者

How can i style mobile-jquery's back button?

开发者 https://www.devze.com 2023-03-20 17:38 出处:网络
normally we could specify data-theme = \"a\" or b or c, etc at any div. however as \"Back\" button is auto generated by jQuery mobile, how to specify its theme?

normally we could specify data-theme = "a" or b or c, etc at any div. however as "Back" button is auto generated by jQuery mobile, how to specify its theme?

Thanks, -开发者_高级运维wan


The button style can be changed using the following:

$.mobile.page.prototype.options.backBtnTheme = "b";


just found out that we could simply put data-theme at header div however it did not fully work -- (change back to blue always) if you click back button once -- and go back to the same page..

it is an existing bug and the workaround is by removeClass below --- and bind it at pagebeforehide.

jQuery("#page_id_e.g.123').removeClass("ui-btn-active");

0

精彩评论

暂无评论...
验证码 换一张
取 消