Knowledge base

Parameters

What are Parameters?

The key to the power of Netbiscuits Device Detection is the parameters (pieces of data) that we provide about the user’s device. With a device library of over 10,000 web-enabled devices, and over 500 hand-tested parameters for each device, the possibilities of how you can customize and optimize a user’s experience are practically endless!

When a user requests a page from your website, Device Detection can tell you that user’s device type, model name, operating system, browser, version of each of these, bandwidth, geolocation, screen size, orientation, and a long, long list of capabilities including HTML, CSS and JavaScript feature support.

Choose which modules, features, and content to send to the user, so they have the best experience possible.

Types of Parameters

Parameters come in two flavors:

  1. Static Parameters

    Most Device Detection parameters are static, in that they are hand-tested and then hard-coded into our device database. Once a static parameter is determined for a device, it is unlikely to ever change. Every similar device will get the same parameter value.

    For example, the parameter devicetype, once detected for a device, is unlikely to ever change; an iPhone will always be a Smartphone, while an iPad will always be a Tablet.

    These parameters are delivered with the initial Device Detection response and will remain the same throughout the user’s browsing session.

  2. Dynamic Parameters

    As the name implies, Dynamic Parameters are “dynamic,” in that they can vary from device to device, even though two devices may be identical. Some dynamic parameters can even vary on a single device during different points of a single browsing session.

    For example, the parameter bandwidth, once detected, can change at any moment, if the user enters a tunnel, or an otherwise weak point in network connectivity. Another good example of a dynamic parameter is geolocation.

    Dynamic parameters are determined on the user’s device after the Device Detection response has been received, and they can update regularly during a browsing session.

    Because dynamic parameters are different than static parameters, they also require a little more attention.

    Learn more about Dynamic Parameters

Parameter List

To view the extensive list of Device Detection parameters, you need to log into a Netbiscuits account. Try it free!

You can either scroll through the list of parameters, or you can start typing something into the search box and the list will automatically reduce itself as you type:
Screenshot of a Parameter List search

How can I access parameters?

First of all, make sure you’ve created a Netbiscuits account and have logged in.

If you’re all set there, and you have a Device Detection option working on your website, then you have two options for accessing the parameters:

  1. Original API

    The original Device Detection API allows you to access all parameters using a “getter” function, like:

    dd.get( 'device.modelname' );

    And receive a response something like:

    "Galaxy S4 Mini"

    Or:

    dd.get( 'device.type' );

    And receive a response something like:

    "Mobile Phone"

    And while this is extremely useful, it does require that you know the full path of the parameter (in the above cases, that modelname and type are both part of the device object).

  2. API 2.0

    We are developing a new API, in which you can use a shorter path to gain access to parameters. For example, while the above two parameters are fairly easy, if you wanted to know if a device can do CSS3 Transforms on the original API, you would have to use the following:

    dd.get( 'browser.css.3transforms.cantransform' ); // true

    Whereas the new API will only have to use the following:

    dd.csstransform; // true

    Below is the full list of parameters currently included in API 2.0, but this is planned to increase rapidly. Unless otherwise noted, these parameters values will be Boolean, indicating that the device either does, or does not, support that feature:

    dd.vendor; // String
    dd.model; // String
    dd.os; // String
    dd.osversion; // String
    dd.browser; // String
    dd.browservendor; // String
    dd.devicetype; // String
    dd.bot;
    dd.desktop;
    dd.tablet;
    dd.smartphone;
    dd.featurephone;
    dd.phone;
    dd.touch;
    dd.pointer;
    dd.fontface;
    dd.localstorage;
    dd.geolocation;
    dd.positionfixed;
    dd.imagemaxwidth; // Numeric
    dd.imagemaxheight; // Numeric
    dd.webm;
    dd.ogg;
    dd.h264;
    dd.svg;
    dd.svginline;
    dd.svgclippath;
    dd.csstransition;
    dd.csstransform;
    dd.csstransform3d;
    dd.csstransformorigin;
    dd.cssperspective;
    dd.cssperspectiveorigin;
    

    And while you are patiently waiting for more parameters to be added to the new API, all parameters are still available via the original API.

Both the original API and the API 2.0 are already available in our entire suite of Device Detection products!

So what are you waiting for?

Try it free!

YouTube aktivieren?

Auf dieser Seite gibt es mind. ein YouTube Video. Cookies für diese Website wurden abgelehnt. Dadurch können keine YouTube Videos mehr angezeigt werden, weil YouTube ohne Cookies und Tracking Mechanismen nicht funktioniert. Willst du YouTube dennoch freischalten?