1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
|
<?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"><![CDATA[
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>
<variablelist>
<varlistentry id="zend.application.available-resources.useragent.methods.init">
<term>
<methodsynopsis>
<methodname>init</methodname>
</methodsynopsis>
</term>
<listitem>
<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>
</listitem>
</varlistentry>
<varlistentry id="zend.application.available-resources.useragent.methods.get-user-agent">
<term>
<methodsynopsis>
<methodname>getUserAgent</methodname>
</methodsynopsis>
</term>
<listitem>
<para>
Instantiates a <classname>Zend_Http_UserAgent</classname> instance, using the
configuration options provided in the application configuration.
</para>
</listitem>
</varlistentry>
</variablelist>
</sect3>
</sect2>
|