mirror of
https://github.com/wassname/cardsforscience.git
synced 2026-06-27 20:20:53 +08:00
Get warning on index.html to work.
This commit is contained in:
+5
-4
@@ -24,15 +24,16 @@
|
||||
<!-- End Google Analytics -->
|
||||
</head>
|
||||
<body>
|
||||
<div id="MobileWarning" class="modal fade bg-warning">
|
||||
<div class="modal-dialog">
|
||||
<div id="MobileWarning" class="modal fade">
|
||||
<div class="modal-dialog bg-warning">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
|
||||
<h4 class="modal-title">Mobile version</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>You seem to be using a mobile device. The experience with this website might be very unpleasant for you. This is why we made a mobile version of Particle Clicker.
|
||||
<p>You seem to be using a mobile device. The experience with this website might be very unpleasant for you. This is why we made a mobile version of Particle Clicker.</p>
|
||||
<p class="small">Hint: If you use the "Save to home screen" function of your browser, you can even play the game in full screen mode.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Understood, but I want to stay here!</button>
|
||||
@@ -242,6 +243,6 @@
|
||||
<script src="js/achievements.js"></script>
|
||||
<script src="js/ui.js"></script>
|
||||
<script src="js/game.js"></script>
|
||||
<script src="js/warnmobile.js></script>
|
||||
<script src="js/warnmobile.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+4
-5
@@ -1,8 +1,7 @@
|
||||
$(function () {
|
||||
'use strict';
|
||||
|
||||
(function() {
|
||||
if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
|
||||
alert('lol');
|
||||
$('#MobileWarning').modal('show');
|
||||
} else {
|
||||
Console.log(navigator.userAgent);
|
||||
}
|
||||
});
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user