Solved

ASP.net VB.net website error trying to create an orientation change for mobiles

Posted on 2014-09-08
4
265 Views
Last Modified: 2014-09-15
Hi
I included the following code in my ASP.net website in order to enable an orientation change when the user flips a mobile device but on running this I get the error shown below

    <script type="text/javascript">
 $(window).on("orientationchange",function(){
    alert("The orientation has changed!");
  });
 </script>

1
0
Comment
Question by:murbro
  • 2
  • 2
4 Comments
 
LVL 82

Expert Comment

by:leakim971
Comment Utility
add jQuery pluginS too
https://developers.google.com/speed/libraries/devguide#jquery

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquerymobile/1.4.3/jquery.mobile.min.js"></script>
0
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
Comment Utility
Check this page : http://jquerymobile.com/download/

if you need CSS add it too :
<link rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jquerymobile/1.4.3/jquery.mobile.min.css" />
0
 

Author Comment

by:murbro
Comment Utility
Thanks. Where do I insert that in my code? I put it just above the code that caused the error and it just said that it wasn't recognised
0
 

Author Closing Comment

by:murbro
Comment Utility
thanks
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Article by: DanRollins
This article describes a JavaScript program that creates a maze made of hexagonal cells.  In Part 2 (http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/A_7850-Hex-Maze-Part-2.html), we'll extend the program by adding a depth-…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. 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.: (CODE)
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…

743 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now