0.0
No commit activity in last 3 years
No release in over 3 years
Ruby client library for mobile handset detection
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 1.0.10
~> 0.2.2
>= 0.9.2
~> 1.0
~> 0.5.3

Runtime

>= 0
>= 0
>= 0
>= 0
 Project Readme

WurflDevice

Ruby client library for mobile handset detection

Requirements

Installation

install using rubygems

gem install wurfl_device

or add to your Gemfile:

gem 'wurfl_device'

and install it via Bundler:

$ bundle

Usage

require 'wurfl_device'

initialize the device cache

WurflDevice.initialize_cache!

get handset capabilities hash from user agent

user_agent = 'Mozilla/5.0 (SymbianOS/9.2; U; Series60/3.1 NokiaN95_8GB/20.0.016; Profile/MIDP-2.0 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413'
capabilities = WurflDevice.handset_from_user_agent(user_agent)

get handset capabilities hash from device id

device_id = 'generic'
capabilities = WurflDevice.handset_from_device_id(device_id)