OSDN Git Service
(root)
/
libre10
/
libre10.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9939e3a
)
implement auto redirect when device is mobile.
author
gn64_jp
<gn64@rec10.org>
Thu, 2 May 2013 12:26:56 +0000
(21:26 +0900)
committer
gn64_jp
<gn64@rec10.org>
Thu, 2 May 2013 12:26:56 +0000
(21:26 +0900)
template/desktop_top.tmpl
patch
|
blob
|
history
diff --git
a/template/desktop_top.tmpl
b/template/desktop_top.tmpl
index
841e3cc
..
ab868fe
100644
(file)
--- a/
template/desktop_top.tmpl
+++ b/
template/desktop_top.tmpl
@@
-12,6
+12,11
@@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script>
$(function(){
+ var agent = navigator.userAgent;
+ var redirectPass = "pdfsearch.pl?mode=mobile";
+ if (agent.search(/iPhone/) != -1 || agent.search(/iPod/) != -1 ||agent.search(/iPad/) != -1 ||agent.search(/Android/) != -1 ){
+ location.href=redirectPass;
+ }
$("#blink").button({
label:"back",
icons:{