开发者

Custom themed header bar in jQuery Mobile

开发者 https://www.devze.com 2023-03-23 08:41 出处:网络
I have a simple question. I want to style the header bar i开发者_如何学Cn jQuery mobile. Specifically I want to set the height of the bar and add a background image to it. How can I do that?

I have a simple question. I want to style the header bar i开发者_如何学Cn jQuery mobile. Specifically I want to set the height of the bar and add a background image to it. How can I do that?

Thank you in advance


This is how I handled it. Instead of actually putting an H1 inside the data-role="header", just directly insert a

<div class="ui-title"></div>

and then add something like this to your custom CSS.

.ui-header .ui-title{
    margin: 0.3em 70px 0.7em 10px;
    background-image:url(../images/logo-page.png);
    background-repeat:no-repeat;
    background-position:0 0px;
    width:178px;
    height:40px;
 }
0

精彩评论

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

关注公众号