Solved

can't get Jquery mobile basic example working

Posted on 2014-11-26
4
92 Views
Last Modified: 2014-11-28
I'm trying out jquery mobile, and I put together this basic code example from the samples on the website.  However the screenshot below shows that the display is cleary not right.  Can someone tell me what I'm doing wrong?  Thanks in advance!

<!DOCTYPE html>
<html>
<head>
	<title>Page Title</title>
	<meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css">
	<script src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
    <script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>
</head>
<body>

<div data-role="page">

	<div data-role="header">
		<h1>Page Title</h1>
	</div>

    <div data-role="controlgroup" data-type="horizontal">
        <a href="#" class="ui-btn ui-corner-all">No icon</a>
        <a href="#" class="ui-btn ui-corner-all ui-icon-delete ui-btn-icon-left">Left</a>
        <a href="#" class="ui-btn ui-corner-all ui-icon-delete ui-btn-icon-right">Right</a>
        <a href="#" class="ui-btn ui-corner-all ui-icon-delete ui-btn-icon-right">More</a>
    </div>

	<div data-role="footer">
		<h4>Page Footer</h4>
	</div>
</div>

</body>
</html>

Open in new window


This is my screenshot in Chrome 39:

chrome 39
And here's my inspector view:

jquery-mobile-devtools-screenshot.jpg
0
Comment
Question by:rustycp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40467882
What are all the non utf characters (the diamond/question mark) ???
0
 
LVL 58

Expert Comment

by:Gary
ID: 40467888
Attach the actual page here.
0
 
LVL 2

Author Comment

by:rustycp
ID: 40467900
Actually that appears to be the problem.  I copied and pasted this code straight from the jquery mobile website and I guess these characters came over with them, but these characters were not viewable in my editor.  I messed around with the encoding in my editor (notepad++) by changing to utf-8 and was able to see all the extraneous characters, and deleted them, and it looks way better now.
0
 
LVL 82

Expert Comment

by:leakim971
ID: 40467916
0

Featured Post

Want Experts Exchange at your fingertips?

With Experts Exchange’s latest app release, you can now experience our most recent features, updates, and the same community interface while on-the-go. Download our latest app release at the Android or Apple stores today!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Chart.js, used properly, can visually add a difference to your charting applications. It engages your visitors and allows them to interact with data they otherwise wouldn't be able to without expensive and complicated systems. For this…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question