This is the code i am using:
<!DOCTYPE html>
<html lang="en">
<head>
<meta name="viewport" content="width=device-width; initial-scale=1.0" />
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.0b1/jquery.mobile-1.0b1.min.css" />
<script src="http://code.jquery.com/jquery-1.6.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.0b1/jquery.mobile-1.0b1.min.js"></script>
</head>
<body>
<div data-role="page" id="home">
<div data-role="header" data-theme="b">
<h1>Home</h1>
</div>
<div data-role="content" data-theme="b">
</div>
<div data-role="footer" data-position="fixed" data-id="pFooter">
<div data-role="navbar">
<ul>
<li><a href="#" data-icon="custom" class="ui-btn-active" >Home</a></li>
<li><a href="#first" data-icon="grid">Page1</a></li>
<li><a href="#" data-icon="star">Page2</a></li>
<li><a href="#" data-icon="arrow-r" data-iconpos="notext"></a></li>
</ul>
</div>
</div>
</div>
</body>
</html>
You can see it in action here- http://jsfiddle.net/PJWQr/
The problem I am facing is that in the last button where I am using data-iconpos="notext"
,the height of the interactive area is lesser than other buttons in the navbar.
Kindly let me know how to fix this.
You actually don't need the iconpos="notext"
as it is not technically a button.
Remove that attribute and add a space character to the content of the a
element:
<li><a href="#" data-icon="arrow-r"> </a></li>
Probably the easy (kind of quick and dirty, but I'm heading to bed so this is what you get ;) is to just but a character there: http://jsfiddle.net/PJWQr/2/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With