On Mon, 07 Sep 2015 20:07:08 +0100, Philip Taylor <p.tay...@rhul.ac.uk>
wrote:

>MiB wrote:
>
>> sep 3 2015 16:16 marie-ange.demeulemees...@bnpparibasfortis.com:
>> 
>>> The only way to detect Android is [J]avaS[c]ript.
>> 
>> It’s kinda pointless attempting to do this yourself as there are frameworks 
>> for this, also commercial. 

>I would respectfully disagree.  It is /never/ pointless to attempt to do
>something oneself that could be accomplished using a library routine /
>framework / w-h-y.  By attempting to do it oneself, one learns; by using
>a library routine / framework / w-h-y, one learns almost nothing.

I agree that trying to do it oneself is never pointless; I will disagree
that using a library routine [including frameworks or what-have-you]
unconditionally leaves one learning almost nothing. If the library
routine is an opaque black box (that is, source is unavailable; all you
get is a chunk of encrypted/compiled code and interface docs), then I
will agree that there is almost nothing that can be learned. However, if
you have access to the source code - which is likely the case for most
things written in JavaScript/ECMAScript - one can learn quite a lot by
reading/reasoning one's way through that code.

At the same time, I will acknowledge - even emphasize - that a published
library routine is /probably/ going to be a better choice in the end
than "rolling your own"; presumably, it will have been tested with a
wide variety of inputs and environments and generally debugged, and will
probably not have undocumented environmental dependencies. Rolling your
own can work, but as soon as you need to use it in a slightly different
context, bugs can turn up and be a headache to stomp on - and the
different context could be as little as an update to the user's browser
(will it work the same on different versions of the same engine, or on
different engines?), or an update to something server-side (PHP5 to
PHP6?), or even changing from running your web server on your home
connection to physically picking it up and moving it to your ISP's co-lo
facility.

-- 
Jeff Zeitlin, Editor
Freelance Traveller
    The Electronic Fan-Supported
    Traveller® Fanzine and Resource

edi...@freelancetraveller.com
http://www.freelancetraveller.com
http://freelancetraveller.downport.com/



®Traveller is a registered trademark of
Far Future Enterprises, 1977-2014. Use of
the trademark in this notice and in the
referenced materials is not intended to
infringe or devalue the trademark.

Freelance Traveller extends its thanks to the following
enterprises for hosting services:

CyberNET Web Hosting (http://www.cyberwebhosting.net)
The Traveller Downport (http://www.downport.com)
______________________________________________________________________
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to