| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!-- Reviewed: no -->
- <sect2 id="zend.application.available-resources.useragent">
- <title>Zend_Application_Resource_Useragent</title>
- <sect3 id="zend.application.available-resources.useragent.intro">
- <title>Overview</title>
- <para>
- This resource provides the ability to configure and instantiate <link
- linkend="zend.http.user-agent">Zend_Http_UserAgent</link> for use within your
- application.
- </para>
- </sect3>
- <sect3 id="zend.application.available-resources.useragent.quick-start">
- <title>Quick Start</title>
- <para>
- Using <classname>Zend_Http_UserAgent</classname>, including usage of the application
- resource, is covered in the <link
- linkend="zend.http.user-agent.quick-start">UserAgent quick start</link>. Below is a
- quick summary of typical options you might provide.
- </para>
- <programlisting language="ini">
- resources.useragent.wurflapi.wurfl_api_version = "1.1"
- resources.useragent.wurflapi.wurfl_lib_dir = APPLICATION_PATH "/../library/Wurfl/1.1"
- resources.useragent.wurflapi.wurfl_config_file = APPLICATION_PATH "/../library/Wurfl/1.1/resources/wurfl-config.php"
- </programlisting>
- </sect3>
- <sect3 id="zend.application.available-resources.useragent.options">
- <title>Configuration Options</title>
- <para>
- Please see the <link linkend="zend.http.user-agent.options">UserAgent options
- section</link> for details on available options.
- </para>
- </sect3>
- <sect3 id="zend.application.available-resources.useragent.methods">
- <title>Available Methods</title>
- <refentry id="zend.application.available-resources.useragent.methods.init">
- <refnamediv>
- <refname>init</refname>
- <refpurpose>Bootstrap/initialize the resource</refpurpose>
- </refnamediv>
- <refsynopsisdiv>
- <methodsynopsis>
- <methodname>init</methodname>
- </methodsynopsis>
- </refsynopsisdiv>
- <refsect1>
- <title>init()</title>
- <para>
- Called by the bootstrap object to initialize the resource. Calls the
- <methodname>getUserAgent()</methodname> method first (and returns the instance
- returned by that method); then, if the "view" resource is available, retrieves
- it and injects the <classname>UserAgent</classname> instance into the
- <classname>UserAgent</classname> view helper.
- </para>
- </refsect1>
- </refentry>
- <refentry id="zend.application.available-resources.useragent.methods.get-user-agent">
- <refnamediv>
- <refname>getUserAgent</refname>
- <refpurpose>Retrieve a configured UserAgent instance</refpurpose>
- </refnamediv>
- <refsynopsisdiv>
- <methodsynopsis>
- <methodname>getUserAgent</methodname>
- </methodsynopsis>
- </refsynopsisdiv>
- <refsect1>
- <title>getUserAgent()</title>
- <para>
- Instantiates a <classname>Zend_Http_UserAgent</classname> instance, using the
- configuration options provided in the application configuration.
- </para>
- </refsect1>
- </refentry>
- </sect3>
- </sect2>
|