17 Oct 2007, 5:53 p.m.

Mobile Device Detection: WURFL and UAProf

None

If you do any kind of development for mobile devices, you'll soon stagger into the minefield of browser and device detection.

Now, this is quite a different sort of challenge to that faced on the desktop web. On the desktop we have maybe one browser worth using, plus a whole lot of people using Internet Explorer, along with a handful of computer programmers who, bewilderingly, persist in using Firefox.

Ok, light-hearted browser snobbery and a few CSS hacks aside, the point is that these days, you basically know where you stand with desktop browsers.

By contrast, when we turn to mobile development, we find we're up against quite literally thousands of subtly and not-so-subtly different devices, and countless combinations of device, firmware and operating system versions. How can we get around this staggering complexity in order to find out the user's screen size? What markup can they handle? What ringtone formats can they accept? How about Java applications and games?

This is where WURFL comes in. WURFL is a free, open-source database of mobile devices and their specifications and capabilities. It is as close to a "standard" solution to this problem as currently exists.

WURFL

The WURFL database is essentially a large (just over 6 Megabytes at the time of writing) XML file. The data is hierarchical and is ultimately keyed by user agent string (as typically supplied in an HTTP request's User-Agent header). The key is mapped to a specific device, and to one or more families of devices, via the "fall_back" mechanism. This allows us, with a bit of work, to build up a list of the device's "capabilities".

If it helps, you can think of this in OO terms as a big stack of classes extending other classes, overriding fields as they go.

Let's try a concrete example. Imagine we come across an agent which identifies itself as "SEC-SGHE950/1.0 NetFront/3.4 Profile/MIDP-2.0 Configuration/CLDC-1.1". Querying WURFL, we find:

;

This tells us...well, nothing! Nothing, beyond the fact that this user agent string is known to WURFL, and thanks to the crucial "fall_back" attribute, we know that it's one of an unspecified number of user agent strings which identify a device or family of devices known internally to WURFL as "samsung_sgh_e950_ver1". So we need to query WURFL again to find the details of this item. Here it is:

This is more like it. We've identified the device (actual_device_root="true"), we have its model number (E950) and its screen size (240 x 320), and we've learned that, ideally, it would like to be served web pages as XHTML-MP. Cool. But there's more: the device falls back further, to "sec_e900_ver1":

Jackpot! We've found out a lot about the device now, in particular the content types it supports. (Note that the model name here is specified as "E900". We can disregard that, as we know it to be overridden one step further down the hierarchy). We can keep going in this manner, successively falling back to "netfront_ver3", "generic_xhtml", "generic" and finally "root". At each stage we pick up a little more information about the device (and at each stage we'll need to disregard a whole bunch of default information too).

Now, I'm sure you're as excited by all of this as I am, but before we get carried away, let's bear in mind that WURFL itself currently weighs in at roughly 127,000 lines of XML. Evidently, recursively querying WURFL directly, in real time, is not a practical option. We'll most likely want to import the data into a relational database, and schedule regular updates. This is going to be a non-trivial task, and is perhaps a topic for a further article.

Alternatives to WURFL

So WURFL's pretty awesome, but it's going to involve some effort on our part to press it into service. Since we're professionals, we'll want to consider whether there are any alternatives which provide better value-for-effort. Well, it turns out that there are alternatives, but they're few and far between. Perhaps the most notable of these few is a mechanism known as "UAProf".

UAProf

UAProf is a W3C initiative, the idea behind which is as follows: the user agent supplies a specific HTTP request header (of which, more in a moment). This header contains the URL of an XML file which describes the capabilities and specifications of the device. The developer programmatically retrieves the XML file, parses it and responds appropriately, typically caching the derived data somehow.

This approach is considered to be attractive, for reasons including:

  • We don't need to do a lot of work up front. When an unfamiliar handset hits our site we simply retrieve the UAProf reactively. Theoretically, maintenance is minimal.
  • UAProf data is supposed to be supplied by the handset manufacturer, thus ensuring it to be correct and up-to-date.

The reality is a little different. I'll loosely quote from Wikipedia here:

  • Not all devices have UAProfs (including many new Windows Mobile devices, iDen handsets, or legacy handsets)
  • Not all advertised UAProfs are available (about 20% of links supplied by handsets are dead or unavailable, according to figures from UAProfile.com)
  • UAProf can contain schema or data errors which can cause parsing to fail
  • Retrieving and parsing UAProfs in real-time is slow and can add substantial overhead to a web request
  • There is no industry-wide data quality standard for the data within each field in a UAProf
  • UAProf headers can often be plain wrong (i.e. for a completely different device)

Add to this that even the name of the HTTP header itself is not clearly defined. Typically, it is "x-wap-profile", but there are several alternatives in the wild right now.

In any case, there's little motivation for manufacturers to provide accurate data. To quote Michael Kaye on the wmlprogramming Yahoo tech group:

We cannot rely on the manufacturers to provide correct information: no company I know of would provide an accurate list of their bugs and misfeatures for the entire world to see.

Quite. All in all, UAProf is considered neither mature nor stable enough to be relied upon in production systems. Moreover, since UAProf is merely one of the sources of data integrated into WURFL in the first place, there's little benefit in developers reinventing the wheel by working with the UAProf mechanism directly.

Other Alternatives

There's a certain amount of talk about how nice it would be if there were an official, centralised, open "Device Description Repository". To this end, the W3C's Mobile Web Initiative has spawned a Device Description Working Group to continue talking - albeit in a more focused manner - about just how nice it would be.

There are commercial offerings too, many of which either layer a Web Services API over WURFL, or attempt to maintain their own database of mobile devices. Inexplicably, dotMobi themselves have hired one of WURFL's original developers and taken the first steps towards setting up their own competing device database.

There's also some activity around automated adaptive rendering technologies. For the .NET developer there's ASP.NET Mobile Controls, but I don't hear a lot of happy noises coming from that direction. For Java and - allegedly - PHP, there's WALL, a tag library somewhat based on WURFL. These may approach some of the minor issues around fragmentation of markup standards.

I have little to no experience with these so I won't be commenting (and I'd be interested to hear from developers with experience of any of the above). Suffice to say, your mileage may vary, and for the time being, WURFL remains a powerful tool in many cases.

Posted by Simon at 01:53:00 PM
18 Aug 2017, 5:26 p.m.

Brianelump

For decades, Wunsiedel, a German town near the Czech border, has struggled with a parade of unwanted visitors.
It is the birthplace of one of Adolf Hitler’s deputies, a man named Rudolf Hess. And every year, to residents’ chagrin, neo-Nazis marched to his grave site there.

6 Sep 2017, 9:34 a.m.

inetryconydot

Order Cheapest Lasix High Quality!

Order cheap Lasix online without a prescription! !

http://rebizsearch.com/dfiles/6.gif


* Secure ordering!
* Free Shipping Worldwide
* Lowest price guaranteed!
* Fully licensed pharmacy
* NO PRESCRIPTION REQUIRED
* Superior customer service 24/7 @ Very easy to get Lasix online!
* 100% Satisfaction Guaranteed
* We accept: VISA, MasterCard, E-check, AMEX and more.



>>> Buy Lasix Right Now <<<

http://rebizsearch.com/thumbs/262_big.jpg

Lasix (Furosemide) is a diuretic that is used to treat fluid accumulation, caused by heart failure, cirrhosis, chronic kidney failure, and nephrotic syndrome.





http://rebizsearch.com/1/e_9.gif

© 2008-2017, Top Pharmacy List! * Medication Without A Prescription! * You Can Find: The Best Quality Pills, Special Discount Medication, Full Information, Best Price Pill Or Capsules, Fast Delivery, Alternative Tablets, Fda Approved Brand & Generic Drugs Without Prescription! No Hidden Costs Or Membership Fees, Easy Ordering Process!



Frequently Asked Questions
- What is the difference between EMS tracking number and Airmail tracking number?
- What does Generic stand for?
- Are your products approved by FDA?











Related search:
Lasix 500 Mg
Lasix 40 Mg Side Effects
Buy Lasix In Usa & Canada
Lasix Cost
Genuine Lasix I Uk Without Prescription
Lasix Brand Name
Buy Lasix Levitra No Prescription Lasix Texas
Purchase Lasix
Buy Insulin U.S. Pharmacy Online
Lasix Mail Order
Lasix Overinght Nottingham
Lasix Tablets
Low Price Lasix Fibromyalgia In Internet Rx Priority Mail South Africa
Suppliers Of Lasix In Uk
Lasix (Furosemide)
Lasix Order
Buylasix 40 Mg
Lasix Mail Order
Acheter,Kaufen,Acquistare Lasix Sale Lasix In Manchester No Prescription
Lasix Online In Canada
Buy Lasix Now Online In Concord
Generic Lasix
Buy Lasix Tablet
Lasix Shipped From Canada
Lasix Cost

2 Jan 2018, 3:01 p.m.

Cheesterzog

купить альбом для монет цена купить альбомы

5 Jan 2018, 5:46 a.m.

Cheesterzog

купить альбом для монет в СПБ. купить альбомы

12 Jan 2018, 1:07 p.m.

Besterzog

Подскажите, что и где ? -для юбилейных 10 альбом нумизмата

17 Jan 2018, 10:52 p.m.

CosterGace

Подскажите, где найти интскуцию на коптер DJI,кроме вот этого сайта? - http://24concord.ru/
Tell me where to find instruction on Copter DJI, except here this site?

2 Feb 2018, 12:36 a.m.

Posterzog

Подскажите, где найти инструкцию на коптер DJI-MAVIC,кроме вот этого сайта? - http://camera7.ru

Tell me where to find instruction on Copter DJI, except here this site?

23 Feb 2018, 9:47 p.m.

Mosterzog

Подскажите, где найти инструкцию на коптер DJI-MAVIC,кроме вот этого сайта? - http://marinaturs.ru

Tell me where to find instruction on Copter DJI, except here this site?

28 Feb 2018, 3:10 a.m.

Prosterzog

Подскажите, где найти инструкцию на коптер DJI-MAVIC,кроме вот этого сайта? - http://www.open-bridge.ru


Tell me where to find instruction on Copter DJI, except here this site? http://open-bridge.ru

6 Mar 2018, 9:41 p.m.

Mosterzog

Подскажите, где найти инструкцию на коптер DJI-MAVIC,кроме вот этого сайта? - http://xerpook.ru

Tell me where to find instruction on Copter DJI, except here this site?

30 Aug 2018, 3:52 p.m.

vitriimpam

Пилатес: эффективность для похудения, польза, противопоказания. Упражнения из пилатеса + особенности занятий.

Грязные методы пикапа
Пилатес: эффективность для похудения, польза, противопоказания. Упражнения из пилатеса + особенности занятий.
Методы съема и пикапа для мужчин, которые позволят легко укладывать девушек в постель. Как общаться с цыпочками, делать их уязвимыми, а потом пользоваться их слабостями? Грязные методы пикапа девушек. Она будет просить пощады в эротическом кружевном нижнем белье.
Пилатес: эффективность для похудения, польза, противопоказания. Упражнения из пилатеса + особенности занятий.
Грязные методы пикапа. Для удачного общения с прекрасным полом следует иногда пользоваться методам, которые в народе именуют пикаперскими. Это грязные приемчики, но они работают. Тебе будет гораздо легче сломать женское сопротивление, если ты будешь к ним прибегать. Можно играть в отношениях с женщинами честно и проигрывать. А можно играть грязно, но побеждать. Что ты выберешь? Грязные методы пикапа. Подорвать уверенность девушки. Многие девушки излишне задирают нос перед мужчинами. Она принцесса, которой достоин только красавчик миллионер. Сейчас мы опустим ее на грешную землю. Для этого пригодится следующий метод пикапа. Нужно заронить зерно сомнения в ее красоте и качествах. Используй подколы, шутки и сомнительные комплименты. Скажи, что уже видел похожую юбку сегодня, ее заколка похожа украшение твоей бабушки, а ее блузка забавная. Легкая ирония и она уже не так уверена в своей привлекательности. Можно задеть ее личные качества, интеллект или характер. Делать это следует с юмором и непринужденно. Теперь девушка не настолько хороша и уже не чувствует себя принцессой. Следовательно, более уязвима и доступна. Это грязный метод пикапа, но он работает на ура. Заставь конкурировать девушку с другими. Другим хорошим способом заинтересовать девушку является конкуренция с другими представительницами прекрасного пола. Даже если это будут воображаемые девушки. Упоминай непринужденно других знакомых девушек, получай от них сообщения в соцсетях и звонки. Для этого попроси своих знакомых девушек или друзей. Пусть девушка знает, что ты востребован, даже если это не совсем правда. Пусть девушка включается в конкурентную борьбу с мифическими врагами. Так будет легче сломить ее сопротивление и починить себе. Говори про чувства и программируй девушку на симпатию. Этот грязный пикап метод является навязыванием эмоций и программированием девушки. Женщины чувствительные, поэтому расскажи ей о любви к животным, путешествиям или хобби. Когда человек чем-то страстно увлекается, это заразительно. Девушка невольно представляет себя на месте этого увлечения. Спроси, в шутку, не влюбилась ли в тебе девушка? Не думает ли она о тебе перед сном? Больше разговоров об отношениях, эмоциональных темах и чувствах. Прикасайся к девушке. Это один из основных и главных приемом пикаперов. Как можно раньше и чаще прикасайся к девушке. Пусть привыкает к твоим рукам и становится менее пугливой. Подавай ей руку, дотрагивайся до разных частей ее тела, соприкасайся ногами или плечами. Прикасайся к девушке, и она быстрей тебе даст. Расшатай нервы девушки. Если играть грязно, то до конца. Девушки очень эмоциональные, что тебе на руку. Очень эффектным методом для пикапа является раскачка нервов и эмоций девушки. Разозли или обидь девушку, но не сильно. А теперь извинись и успокой ее. Будь добр и нежен. Такие эмоциональные качели сделают девушку слабее и уязвимее. Заставляй девушку периодически страдать, и она будет твоей. Раз ты дочитал до сюда, значит ты готов играть грязно. В девушками честные приемы не работают, а хорошие парни спят в одиночестве. Так что играй грязно и побеждай самых красивых цыпочек, плохой парень.
Пилатес: эффективность для похудения, польза, противопоказания. Упражнения из пилатеса + особенности занятий.

8 Sep 2018, 8:14 a.m.

Leroyhoals

锘縱mate is one of several large software massively contacted simply by untold numbers of folks world-wide. this method instance furnishes complete amusement in direction of the user each and every relationship of the users whether from the saddest mood or the climate of total dejection. at times users may well attain the peruse involved with connection to the internet to watch the presentations cyberspace indoors a relaxation vibe. the idea vmate application is give up beneficial to view the instructional videos high street even if you user isn't really acquire the bond of an internet. and, because of regarding iphone app a person could well copy all the required training videos in the immediate access on google android smart phone with troubles. the key reasons why subscribers definite necessity attain the access from this application happens because vmate is fashionable fully accessed with regard to transfering video clips, Songs and as well films makes possible the operator to watch these kind of people hardly any disorders other and / or trouble in the middle.

my application has acknowledge that there are ability to saving it utmost involving unlimited movies and gives the log onto of 200 tv on pc avenues to all you free of charge of priced. this is an app simply important for every google android handsets whereby this tool scholarships free use of a person just for looking for, reviewing and as a result data through several other 100鈥檚 of websites like YouTube facebook. com. the very construtor of these instance also has certain this as large definition 鈥淔astest downloader of video lessons.鈥?accordingly the vmate APK real hdtv occurs over time highly properly plus a more stable strategy. most probably, there are numerous film downloaders appropriate looking, and at present the modern world exceedingly avid together with app nearly due to really good variables. this valuable software seemingly among the better you can get especially sustained with plenty impressive of showcases specific features and can never which learned be all other recently. in so doing, your way through this kind of device the user is going to successfully monitor all the actual movement pictures and video purposes on their own mobile unit, IOS phone vmate or simply on their personal pc. hopefully, sooner than helps see the parts for this software package, when in motion some other with the operation of searching online for.

traits:

designated below are the extreme options that come with this app, look at these businesses

so many a number classes is available every bit of with a single situation with out disturbances.

anyone could endowed that transfer movie films got with various types of types with them

a user ought to highly save movie clips after YouTube, Vimeo as well as DailMotion by a simple faucet

without having affect an individual have the ability to effectively look at just live comfortably television shows

With the greatest harley-davidson the user is going to downloads all newest the movies presentations

genuinely is multi functional activity software package really designated to any or all targeted prospects.

The most astounding interface is probably the greatest positive point to draw a persons

this excellent iphone app is totally free of cost without charging a single dime and thus fully an friends and guests to all slimmers along with no problems.

vmate application best free download in vmate hold

as of today, vmate is one of vmate the best option software package to the media downloading it no various other wonderful continues to some replacement for as yet it. just in case incase a computer owner is hunting for a wonderful app due to grabbing, maybe not a thing any better then this in turn vmate software, Do try out has a tendency to prescribed important features and attain the copy of the software package upon put away hardly any of vmate APK complications and luxuriate in fully span it is rather as exempt from amount.

21 Jan 2019, 11:36 p.m.

MarvinKex

Buy Antibiotics No RX Online - Dr Deepak Agrawal. Most reliable supplier of http://www.drdeepakagrawal.com/wp-content/wc/buyantibiotics/ buy antibiotics online without prescription.
No prescription needed. FREE delivery! Fast and Safe order, Discounts.

3 Jun 2019, 12:29 a.m.

bubShece

причины указанные при разводе
Здравствуйте, уважаемые родители, бабушки и дедушки! Вопрос, который интересует всех и всегда, — сколько весит ваш карапуз и вообще, какая должна быть норма веса новорожденного?

По большому счёту, именно поколение бабушек и дедушек считают вес показателем здоровья. И думают, чем больше вес новорожденного, тем крепче его здоровье.
первая причина развода
В то время, как молодые мамы и папы склоняются к «стройности» своих малышей. Кто прав? И те, и другие. Оптимальный вес новорожденных где-то посередине.

причины для развода с мужем
Какой должен быть нормальный вес новорожденного? ^
https://bubblemom.ru - Беременность, роды, мама и дети. Календарь беременности по неделям

Средний вес новорожденного, родившегося в срок, составляет 2600-4500 грамм. Но стоит учитывать, что это вес, который измеряют сразу после рождения. В первые несколько дней малыш потеряет примерно 5-10% от этого веса. Почему так происходит?

3 Nov 2019, 1:37 a.m.

ZacharyProof

http://pillsgen.site manuscript , bitmap , nested

9 Jul 2021, 8:29 a.m.