Introducción a Zend Framework

 Aprendiendo Zend Framework

Apéndice

 Referencia de Zend Framework


  • Zend_Gdata
  • Zend_Http
  • Zend_InfoCard
  • Zend_Json
  • Zend_Layout
  • Zend_Ldap
  • Zend_Loader
  • Zend_Locale
  • Zend_Log
  • Zend_Mail
  • Zend_Markup
  • Zend_Measure
  • Zend_Memory
  • Zend_Mime
  • Zend_Navigation
  • Zend_Oauth
  • Zend_OpenId
  • Zend_Paginator
  • Zend_Pdf
  • Zend_ProgressBar
  • Zend_Queue
  • Zend_Reflection
  • Zend_Registry
  • Zend_Rest

  • Zend_Search_Lucene
  • Zend_Serializer
  • Zend_Server
  • Zend_Service
  • Zend_Session
  • Zend_Soap
  • Zend_Tag
  • Zend_Test
  • Zend_Text
  • Zend_TimeSync
  • Zend_Tool
  • Zend_Tool_Framework
  • Zend_Tool_Project
  • Zend_Translate
  • Zend_Uri
  • Zend_Validate
  • Zend_Version
  • Zend_View
  • Zend_Wildfire
  • Zend_XmlRpc
  • ZendX_Console_Process_Unix
  • ZendX_JQuery
  • Traducción al 26.9% - Actualizado el 2011-11-16 - Revisión 24249 - Versión ZF 1.11.x

    37.8. The UserAgent Features Adapter

    37.8.1. Overview

    A variety of databases exist that define browser device features and capabilities. Zend_Http_UserAgent provides the ability to utilize the database of your choice via a features adapter interface.

    The features adapter is passed a request array that contains the User-Agent string and any other relevant HTTP headers and environment pertinent to detecting the device in use. Additionally, if any adapter-specific configuration might be needed, an additional configuration array will be provided. The adapter must then return an array of device capabilities.

    37.8.2. Quick Start

    The adapter interface is quite simple, defining but the single static method getFromRequest().

    interface Zend_Http_UserAgent_Features_Adapter
    {
        
    /**
         * Retrieve the browser's features from a given request object ($_SERVER)
         *
         * @return array
         */
        
    public static function getFromRequest($request, array $config);
    }

    37.8.3. Configuration Options

    Options are defined on a per-adapter basis.

    37.8.4. Available Methods

    getFromRequest(array $request, array $config);

    Decompose the request in order to return an array of device capabilities.

    digg delicious meneame google twitter technorati facebook

    Comentarios

    Loading...