[Web4lib] Mobile identification code
Steven Turner
Steven.Turner at usm.edu
Wed Aug 25 12:28:12 EDT 2010
There's an open-source mobile browser detection code that we use at USM libraries which comes in a variety of flavors. Oddly enough it is called 'detect mobile browsers' and is available here:
http://detectmobilebrowser.com/
BTW, it works great, and is updated with OS and device types all the time by the community of users.
On Aug 25, 2010, at 10:08 AM, Thomas Bennett wrote:
> We have a javascript between <head> and </head>
>
> <script>
> if((navigator.userAgent.match(/iPhone/i)) ||
> (navigator.userAgent.match(/iPod/i))) {
> if (document.cookie.indexOf("iphone_redirect=false") == -1) window.location
> = "http://m.library.appstate.edu/";
> }
> </script>
>
> This only works for the iPhone/iPod. it would be simple enough to add in for
> other devices but you would have to do it for each different browser identified.
>
> Found this in nytimes.com
>
> <link rel="alternate" media="handheld" href="http://mobile.nytimes.com">
>
> In an email to this list earlier this year showed where one library had to
> write something like 8 apps or more for mobile users so they could cover the
> major vendors of phones. But this was apps for the phones.
>
> Also, there are broswers for phones that let the user decide which sites to
> view. Such as Skyfire where you can choose to view as desktop or mobile.
> There's Dolphin and Opera Mini where you can toggle mobile view. I use these
> on Droid.
>
>
> Thomas
>
>
>
> On Wednesday 25 August 2010 10:02:08 Dawn Work MaKinne wrote:
>> I don't know to which e-list I should be directing this question. I need
>> the snippet of code that needs to head our Home Page that knows how to
>> identify an incoming user as a mobile user and will direct that user
>> automatically to our mobile site. Is this a fairly direct piece of code,
>> or is it pretty complex? Please let me know what list I need to join to
>> get the answer to this question. Thank you!
>>
>> Dawn Work-MaKinne
>>
>>
>> _______________________________________________
>> Web4lib mailing list
>> Web4lib at webjunction.org
>> http://lists.webjunction.org/web4lib/
>>
>
> --
> ==========================================
> Thomas McMillan Grant Bennett Appalachian State University
> Operations & Systems Analyst P O Box 32026
> University Library Boone, North Carolina 28608
> (828) 262 6587
>
> Library Systems Help Desk: https://www.library.appstate.edu/help/
> ==========================================
>
>
> _______________________________________________
> Web4lib mailing list
> Web4lib at webjunction.org
> http://lists.webjunction.org/web4lib/
>
-----------------------------------------
Steven Turner
Library Web Services Manager
Information Services Librarian
Associate Professor
The University of Southern Mississippi
Cook Library
-----------------------------------------
email: steven.turner at usm.edu
phone: 601.266.4066
-----------------------------------------
More information about the Web4lib
mailing list