Просмотр исходного кода

[MANUAL] English:

- structural fixes (no translations needed)

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@20779 44c647ce-9c0f-0410-b52a-842ac1e357ba
thomas 16 лет назад
Родитель
Сommit
923f72c0b1
19 измененных файлов с 1783 добавлено и 1032 удалено
  1. 72 51
      documentation/manual/en/module_specs/Zend_Gdata-Introduction.xml
  2. 25 24
      documentation/manual/en/module_specs/Zend_Gdata_AuthSub.xml
  3. 29 67
      documentation/manual/en/module_specs/Zend_Gdata_Books.xml
  4. 183 79
      documentation/manual/en/module_specs/Zend_Gdata_Calendar.xml
  5. 12 15
      documentation/manual/en/module_specs/Zend_Gdata_ClientLogin.xml
  6. 17 8
      documentation/manual/en/module_specs/Zend_Gdata_Docs.xml
  7. 23 19
      documentation/manual/en/module_specs/Zend_Gdata_Exception.xml
  8. 15 43
      documentation/manual/en/module_specs/Zend_Gdata_Gapps.xml
  9. 146 43
      documentation/manual/en/module_specs/Zend_Gdata_Gbase.xml
  10. 197 84
      documentation/manual/en/module_specs/Zend_Gdata_Health.xml
  11. 183 96
      documentation/manual/en/module_specs/Zend_Gdata_Photos.xml
  12. 17 15
      documentation/manual/en/module_specs/Zend_Gdata_Spreadsheets.xml
  13. 284 215
      documentation/manual/en/module_specs/Zend_Gdata_YouTube.xml
  14. 140 53
      documentation/manual/en/module_specs/Zend_Http_Client-Adapters.xml
  15. 70 20
      documentation/manual/en/module_specs/Zend_Http_Client-Advanced.xml
  16. 59 11
      documentation/manual/en/module_specs/Zend_Http_Client.xml
  17. 203 134
      documentation/manual/en/module_specs/Zend_Http_Cookie-Handling.xml
  18. 91 38
      documentation/manual/en/module_specs/Zend_Http_Response.xml
  19. 17 17
      documentation/manual/en/module_specs/Zend_InfoCard-Basics.xml

+ 72 - 51
documentation/manual/en/module_specs/Zend_Gdata-Introduction.xml

@@ -2,16 +2,16 @@
 <!-- Reviewed: no -->
 <sect1 id="zend.gdata.introduction">
     <title>Introduction</title>
+
     <para>
         Google Data <acronym>API</acronym>s provide programmatic interface to some of Google's
-        online services. The Google data Protocol is based upon the
-        <ulink url="http://ietfreport.isoc.org/idref/draft-ietf-atompub-protocol/">Atom Publishing Protocol</ulink>
-        and allows client applications to retrieve data matching queries,
+        online services. The Google data Protocol is based upon the <ulink
+            url="http://ietfreport.isoc.org/idref/draft-ietf-atompub-protocol/">Atom Publishing
+            Protocol</ulink> and allows client applications to retrieve data matching queries,
         post data, update data and delete data using standard <acronym>HTTP</acronym> and the
-        Atom syndication formation.
-
-        The <classname>Zend_Gdata</classname> component is a <acronym>PHP</acronym> 5 interface for accessing Google Data
-        from <acronym>PHP</acronym>. The <classname>Zend_Gdata</classname> component also supports accessing other services
+        Atom syndication formation. The <classname>Zend_Gdata</classname> component is a
+        <acronym>PHP</acronym> 5 interface for accessing Google Data from <acronym>PHP</acronym>.
+        The <classname>Zend_Gdata</classname> component also supports accessing other services
         implementing the Atom Publishing Protocol.
     </para>
 
@@ -32,6 +32,7 @@
                     is a popular online calendar application.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.spreadsheets">Google Spreadsheets</link>
@@ -39,6 +40,7 @@
                     can be used as a simple data store for your applications.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.docs">Google Documents List</link>
@@ -46,6 +48,7 @@
                     and presentations stored in a Google account.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.gapps">Google Provisioning</link>
@@ -54,6 +57,7 @@
                     Google Apps hosted domain.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.gbase">Google Base</link>
@@ -61,6 +65,7 @@
                     delete items in Google Base.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.youtube">YouTube</link>
@@ -69,25 +74,30 @@
                     and more.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <link linkend="zend.gdata.photos">Picasa Web Albums</link>
                     provides an online photo sharing application.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <ulink url="http://code.google.com/apis/blogger/developers_guide_php.html">Google Blogger</ulink>
-                    is a popular Internet provider of
+                    <ulink
+                        url="http://code.google.com/apis/blogger/developers_guide_php.html">Google
+                        Blogger</ulink> is a popular Internet provider of
                     "push-button publishing" and syndication.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     Google CodeSearch
                     allows you to search public source code from many projects.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     Google Notebook
@@ -99,6 +109,7 @@
 
     <note>
         <title>Unsupported services</title>
+
         <para>
             <classname>Zend_Gdata</classname> does not provide an interface to any other Google
             service, such as Search, Gmail, Translation, or Maps.
@@ -108,8 +119,10 @@
 
     <sect2 id="zend.gdata.introduction.structure">
         <title>Structure of Zend_Gdata</title>
+
         <para>
             <classname>Zend_Gata</classname> is composed of several types of classes:
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -121,6 +134,7 @@
                         entries, update entries and delete entries.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         Query classes - inheriting from <classname>Zend_Gdata_Query</classname>.
@@ -139,6 +153,7 @@
                         method.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         Feed classes - inheriting from <classname>Zend_Gdata_App_Feed</classname>.
@@ -151,11 +166,13 @@
                         data returned from services.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         Entry classes - inheriting from <classname>Zend_Gdata_App_Entry</classname>.
                         These also include other classes such as
-                        <classname>Zend_Gdata_Entry</classname>, and <classname>Zend_Gdata_Spreadsheets_ListEntry</classname>.
+                        <classname>Zend_Gdata_Entry</classname>, and
+                        <classname>Zend_Gdata_Spreadsheets_ListEntry</classname>.
                         These classes represent entries retrieved from
                         services or used for constructing data to send to
                         services. In addition to being able to set the
@@ -168,12 +185,14 @@
                         to delete an entry from the server.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         Other Data model classes - inheriting from
                         <classname>Zend_Gdata_App_Extension</classname>. These include classes such
                         as <classname>Zend_Gdata_App_Extension_Title</classname> (representing the
-                        atom:title <acronym>XML</acronym> element), <classname>Zend_Gdata_Extension_When</classname>
+                        atom:title <acronym>XML</acronym> element),
+                        <classname>Zend_Gdata_Extension_When</classname>
                         (representing the gd:when <acronym>XML</acronym> element used by the
                         GData Event "Kind"), and
                         <classname>Zend_Gdata_Extension_Cell</classname> (representing the gs:cell
@@ -200,19 +219,20 @@
 
     <sect2 id="zend.gdata.introduction.services">
         <title>Interacting with Google Services</title>
+
         <para>
             Google data services are based upon the Atom Publishing Protocol
             (APP) and the Atom syndication format. To interact with APP or
             Google services using the <classname>Zend_Gdata</classname> component, you need to use
-            the service classes such as <classname>Zend_Gdata_App</classname>, <classname>Zend_Gdata</classname>,
-            <classname>Zend_Gdata_Spreadsheets</classname>, etc. These service classes provide
-            methods to retrieve data from services as feeds, insert new
-            entries into feeds, update entries, and delete entries.
+            the service classes such as <classname>Zend_Gdata_App</classname>,
+            <classname>Zend_Gdata</classname>, <classname>Zend_Gdata_Spreadsheets</classname>, etc.
+            These service classes provide methods to retrieve data from services as feeds, insert
+            new entries into feeds, update entries, and delete entries.
         </para>
 
         <para>
-            Note: A full example of working with <classname>Zend_Gdata</classname> is available in the
-            <code>demos/Zend/Gdata</code> directory. This example is runnable
+            Note: A full example of working with <classname>Zend_Gdata</classname> is available in
+            the <code>demos/Zend/Gdata</code> directory. This example is runnable
             from the command-line, but the methods contained within are easily
             portable to a web application.
         </para>
@@ -220,6 +240,7 @@
 
     <sect2 id="zend.gdata.introduction.magicfactory">
         <title>Obtaining instances of Zend_Gdata classes</title>
+
         <para>
             The Zend Framework naming standards require that all classes be
             named based upon the directory structure in which they are located.
@@ -230,12 +251,13 @@
             This causes a lot of typing if you're trying to construct a new
             instance of a spreadsheet cell element!
         </para>
+
         <para>
             We've implemented a magic factory method in all service classes
-            (such as <classname>Zend_Gdata_App</classname>, <classname>Zend_Gdata</classname>, <classname>Zend_Gdata_Spreadsheets</classname>) that
-            should make constructing new instances of data model, query and
-            other classes much easier. This magic factory is implemented by
-            using the magic <code>__call</code> method to intercept all attempts
+            (such as <classname>Zend_Gdata_App</classname>, <classname>Zend_Gdata</classname>,
+            <classname>Zend_Gdata_Spreadsheets</classname>) that should make constructing new
+            instances of data model, query and other classes much easier. This magic factory is
+            implemented by using the magic <code>__call</code> method to intercept all attempts
             to call <code>$service->newXXX(arg1, arg2, ...)</code>. Based off
             the value of XXX, a search is performed in all registered 'packages'
             for the desired class. Here's some examples:
@@ -266,6 +288,7 @@ $entry->cell = $cell;
 
     <sect2 id="zend.gdata.introduction.authentication">
         <title>Google Data Client Authentication</title>
+
         <para>
             Most Google Data services require client applications to
             authenticate against the Google server before accessing
@@ -280,34 +303,34 @@ $entry->cell = $cell;
             Most other types of queries against Google Data services do not
             require authentication.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.dependencies">
         <title>Dependencies</title>
+
         <para>
             <classname>Zend_Gdata</classname> makes use of
             <link linkend="zend.http.client">Zend_Http_Client</link> to send
             requests to google.com and fetch results. The response to most
             Google Data requests is returned as a subclass of the
-            <classname>Zend_Gdata_App_Feed</classname> or <classname>Zend_Gdata_App_Entry</classname> classes.
+            <classname>Zend_Gdata_App_Feed</classname> or
+            <classname>Zend_Gdata_App_Entry</classname> classes.
         </para>
 
         <para>
-            <classname>Zend_Gdata</classname> assumes your <acronym>PHP</acronym> application is running on a host that
-            has a direct connection to the Internet.
+            <classname>Zend_Gdata</classname> assumes your <acronym>PHP</acronym> application is
+            running on a host that has a direct connection to the Internet.
             The <classname>Zend_Gdata</classname> client operates by contacting Google Data servers.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.creation">
         <title>Creating a new Gdata client</title>
 
         <para>
-            Create a new object of class <classname>Zend_Gdata_App</classname>, <classname>Zend_Gdata</classname>, or one
-            of the subclasses available that offer helper methods for
-            service-specific behavior.
+            Create a new object of class <classname>Zend_Gdata_App</classname>,
+            <classname>Zend_Gdata</classname>, or one of the subclasses available that offer helper
+            methods for service-specific behavior.
         </para>
 
         <para>
@@ -351,7 +374,6 @@ $gdata->setMinorProtocolVersion(null);
             Also see the sections on authentication for methods to
             create an authenticated <classname>Zend_Http_Client</classname> object.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.parameters">
@@ -359,10 +381,10 @@ $gdata->setMinorProtocolVersion(null);
 
         <para>
             You can specify parameters to customize queries with <classname>Zend_Gdata</classname>.
-            Query parameters are specified using subclasses of <classname>Zend_Gdata_Query</classname>.
-            The <classname>Zend_Gdata_Query</classname> class includes methods to set all query
-            parameters used throughout GData services. Individual services,
-            such as Spreadsheets, also provide query classes to defined
+            Query parameters are specified using subclasses of
+            <classname>Zend_Gdata_Query</classname>. The <classname>Zend_Gdata_Query</classname>
+            class includes methods to set all query parameters used throughout GData services.
+            Individual services, such as Spreadsheets, also provide query classes to defined
             parameters which are custom to the particular service and feeds.
             Spreadsheets includes a CellQuery class to query the Cell Feed
             and a ListQuery class to query the List Feed, as different
@@ -377,6 +399,7 @@ $gdata->setMinorProtocolVersion(null);
                     The <code>q</code> parameter specifies a full-text
                     query. The value of the parameter is a string.
                 </para>
+
                 <para>
                     Set this parameter with the <methodname>setQuery()</methodname>
                     function.
@@ -399,6 +422,7 @@ $gdata->setMinorProtocolVersion(null);
                     feeds in other formats, using query <acronym>URL</acronym>s generated by the
                     <classname>Zend_Gdata_Query</classname> class and its subclasses.
                 </para>
+
                 <para>
                     Set this parameter with the <methodname>setAlt()</methodname>
                     function.
@@ -412,9 +436,9 @@ $gdata->setMinorProtocolVersion(null);
                     an integer. The number of entries returned in the feed
                     will not exceed this value.
                 </para>
+
                 <para>
-                    Set this parameter with the <methodname>setMaxResults()</methodname>
-                    function.
+                    Set this parameter with the <methodname>setMaxResults()</methodname> function.
                 </para>
             </listitem>
 
@@ -424,6 +448,7 @@ $gdata->setMinorProtocolVersion(null);
                     ordinal number of the first entry returned in the feed.
                     Entries before this number are skipped.
                 </para>
+
                 <para>
                     Set this parameter with the <methodname>setStartIndex()</methodname>
                     function.
@@ -440,22 +465,22 @@ $gdata->setMinorProtocolVersion(null);
                     no entries updated after the date specified by
                     <code>updatedMax</code> are included.
                 </para>
+
                 <para>
                     You can use numeric timestamps, or a variety of
                     date/time string representations as the value for
                     these parameters.
                 </para>
+
                 <para>
                     Set this parameter with the <methodname>setUpdatedMin()</methodname>
                     and <methodname>setUpdatedMax()</methodname> functions.
                 </para>
             </listitem>
-
         </itemizedlist>
 
         <para>
-            There is a <code>get</code> function for each
-            <code>set</code> function.
+            There is a <code>get</code> function for each <code>set</code> function.
         </para>
 
         <programlisting language="php"><![CDATA[
@@ -490,7 +515,6 @@ $query->maxResults = 10;
 $query->resetParameters();      // clears all parameters
 // ...get a different feed...
 ]]></programlisting>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.getfeed">
@@ -518,7 +542,6 @@ $feed = $gdata->getFeed($query);
             functions help you to get feeds from the <acronym>URI</acronym> that is
             appropriate for the respective service.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.paging">
@@ -564,7 +587,6 @@ $feed = $gdata->retrieveAllEntriesForFeed($gdata->getFeed($query));
             time to complete on large feeds. You may need to increase <acronym>PHP</acronym>'s
             execution time limit by calling <methodname>set_time_limit()</methodname>.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.usefeedentry">
@@ -663,18 +685,18 @@ echo 'The <id> of the resulting entry is: ' . $entryResult->id->text;
 
         <para>
             To post entries, you must be using an authenticated
-            <classname>Zend_Http_Client</classname> that you created using the <classname>Zend_Gdata_AuthSub</classname>
-            or <classname>Zend_Gdata_ClientLogin</classname> classes.
+            <classname>Zend_Http_Client</classname> that you created using the
+            <classname>Zend_Gdata_AuthSub</classname> or
+            <classname>Zend_Gdata_ClientLogin</classname> classes.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.introduction.delete">
         <title>Deleting Entries on Google Servers</title>
 
         <para>
-            Option 1: The <classname>Zend_Gdata</classname> object has a function <methodname>delete()</methodname>
-            with which you can delete entries from Google Data
+            Option 1: The <classname>Zend_Gdata</classname> object has a function
+            <methodname>delete()</methodname> with which you can delete entries from Google Data
             services. Pass the edit <acronym>URL</acronym> value from
             a feed entry to the <methodname>delete()</methodname> method.
         </para>
@@ -700,10 +722,9 @@ foreach ($feed as $feedEntry) {
 
         <para>
             To delete entries, you must be using an authenticated
-            <classname>Zend_Http_Client</classname> that you created using the <classname>Zend_Gdata_AuthSub</classname>
-            or <classname>Zend_Gdata_ClientLogin</classname> classes.
+            <classname>Zend_Http_Client</classname> that you created using the
+            <classname>Zend_Gdata_AuthSub</classname> or
+            <classname>Zend_Gdata_ClientLogin</classname> classes.
         </para>
-
     </sect2>
-
 </sect1>

+ 25 - 24
documentation/manual/en/module_specs/Zend_Gdata_AuthSub.xml

@@ -10,7 +10,8 @@
     </para>
 
     <para>
-        See <ulink url="http://code.google.com/apis/accounts/AuthForWebApps.html">http://code.google.com/apis/accounts/AuthForWebApps.html</ulink>
+        See <ulink
+            url="http://code.google.com/apis/accounts/AuthForWebApps.html">http://code.google.com/apis/accounts/AuthForWebApps.html</ulink>
         for more information about Google Data AuthSub authentication.
     </para>
 
@@ -32,9 +33,10 @@
 
     <note>
         <title>Registered applications</title>
+
         <para>
-            <classname>Zend_Gdata</classname> currently does not support use of secure tokens, because
-            the AuthSub authentication does not support passing a digital certificate
+            <classname>Zend_Gdata</classname> currently does not support use of secure tokens,
+            because the AuthSub authentication does not support passing a digital certificate
             to acquire a secure token.
         </para>
     </note>
@@ -47,8 +49,8 @@
             Google <acronym>URL</acronym> that performs authentication. The static function
             <methodname>Zend_Gdata_AuthSub::getAuthSubTokenUri()</methodname>
             provides the correct <acronym>URL</acronym>. The arguments to this function include
-            the <acronym>URL</acronym> to your <acronym>PHP</acronym> application so that Google can redirect the
-            user's browser back to your application after the user's
+            the <acronym>URL</acronym> to your <acronym>PHP</acronym> application so that Google can
+            redirect the user's browser back to your application after the user's
             credentials have been verified.
         </para>
 
@@ -104,7 +106,6 @@ $client = Zend_Gdata_AuthSub::getHttpClient($_SESSION['cal_token']);
 // Create a Gdata object using the authenticated Http Client
 $cal = new Zend_Gdata_Calendar($client);
 ]]></programlisting>
-
     </sect2>
 
     <sect2 id="zend.gdata.authsub.logout">
@@ -132,23 +133,23 @@ if (isset($_GET['logout'])) {
 }
 ]]></programlisting>
 
-    <note>
-        <title>Security notes</title>
-        <para>
-            The treatment of the <varname>$php_self</varname> variable in the
-            example above is a general security guideline, it is not
-            specific to <classname>Zend_Gdata</classname>. You should always filter content you
-            output to http headers.
-        </para>
-        <para>
-            Regarding revoking authentication tokens, it is recommended to
-            do this when the user is finished with her Google Data session.
-            The possibility that someone can intercept the token and use
-            it for malicious purposes is very small, but nevertheless it is
-            a good practice to terminate authenticated access to any service.
-        </para>
-    </note>
-
+        <note>
+            <title>Security notes</title>
+
+            <para>
+                The treatment of the <varname>$php_self</varname> variable in the
+                example above is a general security guideline, it is not
+                specific to <classname>Zend_Gdata</classname>. You should always filter content you
+                output to http headers.
+            </para>
+
+            <para>
+                Regarding revoking authentication tokens, it is recommended to
+                do this when the user is finished with her Google Data session.
+                The possibility that someone can intercept the token and use
+                it for malicious purposes is very small, but nevertheless it is
+                a good practice to terminate authenticated access to any service.
+            </para>
+        </note>
     </sect2>
-
 </sect1>

+ 29 - 67
documentation/manual/en/module_specs/Zend_Gdata_Books.xml

@@ -13,19 +13,18 @@
         full-text searches for books and to retrieve standard book information,
         ratings, and reviews. You can also access individual users'
         <ulink url="http://books.google.com/googlebooks/mylibrary/">library collections and
-        public reviews</ulink>. Finally, your application can submit authenticated requests
+            public reviews</ulink>. Finally, your application can submit authenticated requests
         to enable users to create and modify library collections, ratings, labels,
         reviews, and other account-specific entities.
     </para>
 
     <para>
-        For more information on the Book Search Data <acronym>API</acronym>, please refer to the official
-        <ulink url="http://code.google.com/apis/books/gdata/developers_guide_php.html">PHP
-        Developer's Guide</ulink> on code.google.com.
+        For more information on the Book Search Data <acronym>API</acronym>, please refer to the
+        official <ulink url="http://code.google.com/apis/books/gdata/developers_guide_php.html">PHP
+            Developer's Guide</ulink> on code.google.com.
     </para>
 
     <sect2 id="zend.gdata.books.authentication">
-
         <title>Authenticating to the Book Search service</title>
 
         <para>
@@ -36,18 +35,17 @@
             requesting private feeds. It can authenticate using either of two
             approaches: AuthSub proxy authentication or ClientLogin username/password
             authentication. Please refer to the <ulink
-            url="http://code.google.com/apis/books/gdata/developers_guide_php.html#Authentication">
-            Authentication section in the <acronym>PHP</acronym> Developer's Guide</ulink> for more detail.
+                url="http://code.google.com/apis/books/gdata/developers_guide_php.html#Authentication">Authentication
+                section in the <acronym>PHP</acronym> Developer's Guide</ulink> for more detail.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.books.searching_for_books">
-
         <title>Searching for books</title>
 
         <para>
-            The Book Search Data <acronym>API</acronym> provides a number of feeds that list collections of books.
+            The Book Search Data <acronym>API</acronym> provides a number of feeds that list
+            collections of books.
         </para>
 
         <para>
@@ -84,8 +82,8 @@ foreach ($feed as $entry) {
         <para>
             The <code>Query</code> class, and subclasses like
             <code>VolumeQuery</code>, are responsible for constructing feed
-            <acronym>URL</acronym>s. The VolumeQuery shown above constructs a <acronym>URL</acronym> equivalent to the
-            following:
+            <acronym>URL</acronym>s. The VolumeQuery shown above constructs a <acronym>URL</acronym>
+            equivalent to the following:
         </para>
 
         <programlisting language="php"><![CDATA[
@@ -147,11 +145,10 @@ http://www.google.com/books/feeds/volumes?q=keyword&amp;min-viewability=partial
         </para>
 
         <para>
-            <code>setMinViewability:</code>
-            Allows you to filter the results according to the books'
-            <ulink url="http://code.google.com/apis/books/docs/dynamic-links.html#terminology">
-            viewability status</ulink>.
-            This parameter accepts one of three values: <code>'none'</code>
+            <code>setMinViewability:</code> Allows you to filter the results according to the books'
+            <ulink
+                url="http://code.google.com/apis/books/docs/dynamic-links.html#terminology">viewability
+                status</ulink>. This parameter accepts one of three values: <code>'none'</code>
             (the default, returning all matching books regardless of
             viewability), <code>'partial_view'</code> (returning only books
             that the user can preview or view in their entirety), or
@@ -160,21 +157,21 @@ http://www.google.com/books/feeds/volumes?q=keyword&amp;min-viewability=partial
         </para>
 
         <sect3 id="zend.gdata.books.partner_restrict">
-
             <title>Partner Co-Branded Search</title>
 
             <para>
                 Google Book Search provides <ulink
-                url="http://books.google.com/support/partner/bin/answer.py?hl=en&amp;answer=65113">
-                Co-Branded Search</ulink>, which lets content partners provide full-text search of
+                    url="http://books.google.com/support/partner/bin/answer.py?hl=en&amp;answer=65113">Co-Branded
+                    Search</ulink>, which lets content partners provide full-text search of
                 their books from their own websites.
             </para>
 
             <para>
                 If you are a partner who wants to do Co-Branded Search using the
-                Book Search Data <acronym>API</acronym>, you may do so by modifying the feed <acronym>URL</acronym> above to
-                point to your Co-Branded Search implementation. If, for example, a
-                Co-Branded Search is available at the following <acronym>URL</acronym>:
+                Book Search Data <acronym>API</acronym>, you may do so by modifying the feed
+                <acronym>URL</acronym> above to point to your Co-Branded Search implementation. if,
+                for example, a Co-Branded Search is available at the following
+                <acronym>URL</acronym>:
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -182,8 +179,8 @@ http://www.google.com/books/p/PARTNER_COBRAND_ID?q=ball
 ]]></programlisting>
 
             <para>
-                then you can obtain the same results using the Book Search Data <acronym>API</acronym> at the
-                following <acronym>URL</acronym>:
+                then you can obtain the same results using the Book Search Data
+                <acronym>API</acronym> at the following <acronym>URL</acronym>:
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -204,17 +201,13 @@ $query =
                 For additional information or support, visit our
                 <ulink url="http://books.google.com/support/partner/">Partner help center</ulink>.
             </para>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.books.community_features">
-
         <title>Using community features</title>
 
         <sect3 id="zend.gdata.books.adding_ratings">
-
             <title>Adding a rating</title>
 
             <para>
@@ -235,22 +228,19 @@ $entry->setId(new Zend_Gdata_App_Extension_Id(VOLUME_ID));
 $entry->setRating(new Zend_Gdata_Extension_Rating(3, 1, 5, 1));
 $books->insertVolume($entry, Zend_Gdata_Books::MY_ANNOTATION_FEED_URI);
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.books.reviews">
-
             <title>Reviews</title>
 
             <para>
                 In addition to ratings, authenticated users can submit reviews or
                 edit their reviews. For information on how to request previously
                 submitted reviews, see <ulink
-                url="#zend.gdata.books.retrieving_annotations">Retrieving annotations</ulink>.
+                    url="#zend.gdata.books.retrieving_annotations">Retrieving annotations</ulink>.
             </para>
 
             <sect4 id="zend.gdata.books.adding_review">
-
                 <title>Adding a review</title>
 
                 <para>
@@ -268,11 +258,9 @@ $review->setText("This book is amazing!");
 $entry->setReview($review);
 $books->insertVolume($entry, $annotationUrl);
 ]]></programlisting>
-
             </sect4>
 
             <sect4 id="zend.gdata.books.editing_review">
-
                 <title>Editing a review</title>
 
                 <para>
@@ -289,24 +277,20 @@ $review->setText("This book is actually not that good!");
 $entry->setReview($review);
 $books->updateVolume($entry, $entryUrl);
 ]]></programlisting>
-
             </sect4>
-
         </sect3>
 
         <sect3 id="zend.gdata.books.labels">
-
             <title>Labels</title>
 
             <para>
                 You can use the Book Search Data <acronym>API</acronym> to label volumes with
                 keywords. A user can submit, retrieve and modify labels. See
                 <ulink url="#zend.gdata.books.retrieving_annotations">Retrieving
-                annotations</ulink> for how to read previously submitted labels.
+                    annotations</ulink> for how to read previously submitted labels.
             </para>
 
             <sect4 id="zend.gdata.books.submitting_labels">
-
                 <title>Submitting a set of labels</title>
 
                 <para>
@@ -323,13 +307,10 @@ $category      = new Zend_Gdata_App_Extension_Category(
 $entry->setCategory(array($category));
 $books->insertVolume($entry, Zend_Gdata_Books::MY_ANNOTATION_FEED_URI);
 ]]></programlisting>
-
             </sect4>
-
         </sect3>
 
         <sect3 id="zend.gdata.books.retrieving_annotations">
-
             <title>Retrieving annotations: reviews, ratings, and labels</title>
 
             <para>
@@ -362,11 +343,9 @@ foreach ($feed as $entry) {
                 <ulink url="#zend.gdata.books.query_parameters">query parameters</ulink>
                 section.
             </para>
-
         </sect3>
 
         <sect3 id="zend.gdata.books.deleting_annotations">
-
             <title>Deleting Annotations</title>
 
             <para>
@@ -378,13 +357,10 @@ foreach ($feed as $entry) {
             <programlisting language="php"><![CDATA[
 $books->deleteVolume($entry);
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.books.sharing_with_my_library">
-
         <title>Book collections and My Library</title>
 
         <para>
@@ -397,11 +373,10 @@ $books->deleteVolume($entry);
             represents the books the user would like to remember, organize, and
             share with others. This is the collection the user sees when accessing
             his or her <ulink url="http://books.google.com/books?op=library">My Library
-            page</ulink>.
+                page</ulink>.
         </para>
 
         <sect3 id="zend.gdata.books.retrieving_books_in_library">
-
             <title>Retrieving books in a user's library</title>
 
             <para>
@@ -415,7 +390,6 @@ $books->deleteVolume($entry);
             </para>
 
             <sect4 id="zend.gdata.books.retrieving_all_books_in_library">
-
                 <title>Retrieving all books in a user's library</title>
 
                 <para>
@@ -434,16 +408,14 @@ $feed = $books->getUserLibraryFeed();
                     more information, see the <code>max-results</code> query parameter in
                     <ulink url="#zend.gdata.books.searching_for_books">Searching for books</ulink>.
                 </para>
-
             </sect4>
 
             <sect4 id="zend.gdata.books.retrieving_books_in_library_with_query">
-
                 <title>Searching for books in a user's library</title>
 
                 <para>
                     Just as you can <ulink
-                    url="#zend.gdata.books.searching_for_books">search across all books</ulink>,
+                        url="#zend.gdata.books.searching_for_books">search across all books</ulink>,
                     you can do a full-text search over just the books in a
                     user's library. To do this, just set the appropriate
                     paramters on the <code>VolumeQuery</code> object.
@@ -477,25 +449,21 @@ $query->setCategory(
 $query->setCategory('favorites');
 $feed = $books->getVolumeFeed($query);
 ]]></programlisting>
-
             </sect4>
-
         </sect3>
 
         <sect3 id="zend.gdata.books.updating_library">
-
             <title>Updating books in a user's library</title>
 
             <para>
-                You can use the Book Search Data <acronym>API</acronym> to add a book to, or remove a
-                book from, a user's library. Ratings, reviews, and labels are valid
+                You can use the Book Search Data <acronym>API</acronym> to add a book to, or remove
+                a book from, a user's library. Ratings, reviews, and labels are valid
                 across all the collections of a user, and are thus edited using the
                 annotation feed (see <ulink
-                url="#zend.gdata.books.community_features">Using community features</ulink>).
+                    url="#zend.gdata.books.community_features">Using community features</ulink>).
             </para>
 
             <sect4 id="zend.gdata.books.library_book_add">
-
                 <title>Adding a book to a library</title>
 
                 <para>
@@ -531,11 +499,9 @@ $books->insertVolume(
     Zend_Gdata_Books::MY_LIBRARY_FEED_URI
 );
 ]]></programlisting>
-
             </sect4>
 
             <sect4 id="zend.gdata.books.library_book_remove">
-
                 <title>Removing a book from a library</title>
 
                 <para>
@@ -546,11 +512,7 @@ $books->insertVolume(
                 <programlisting language="php"><![CDATA[
 $books->deleteVolume($entry);
 ]]></programlisting>
-
             </sect4>
-
         </sect3>
-
     </sect2>
-
 </sect1>

+ 183 - 79
documentation/manual/en/module_specs/Zend_Gdata_Calendar.xml

@@ -2,39 +2,49 @@
 <!-- Reviewed: no -->
 <sect1 id="zend.gdata.calendar">
     <title>Using Google Calendar</title>
+
     <para>
         You can use the
         <classname>Zend_Gdata_Calendar</classname>
         class to view, create, update, and delete events in the online Google Calendar service.
     </para>
+
     <para>
         See <ulink
         url="http://code.google.com/apis/calendar/overview.html">
         http://code.google.com/apis/calendar/overview.html</ulink>
         for more information about the Google Calendar <acronym>API</acronym>.
     </para>
+
     <sect2 id="zend.gdata.calendar.connecting">
         <title>Connecting To The Calendar Service</title>
+
         <para>
-            The Google Calendar <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is based off of the Atom Publishing
-            Protocol (APP), an <acronym>XML</acronym> based format for managing web-based resources. Traffic between
-            a client and the Google Calendar servers occurs over <acronym>HTTP</acronym> and allows for both
-            authenticated and unauthenticated connections.
+            The Google Calendar <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is
+            based off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based format
+            for managing web-based resources. Traffic between a client and the Google Calendar
+            servers occurs over <acronym>HTTP</acronym> and allows for both authenticated and
+            unauthenticated connections.
         </para>
+
         <para>
             Before any transactions can occur, this connection needs to be made. Creating a
-            connection to the calendar servers involves two steps: creating an <acronym>HTTP</acronym> client and
-            binding a <classname>Zend_Gdata_Calendar</classname> service instance to that client.
+            connection to the calendar servers involves two steps: creating an
+            <acronym>HTTP</acronym> client and binding a <classname>Zend_Gdata_Calendar</classname>
+            service instance to that client.
         </para>
+
         <sect3 id="zend.gdata.calendar.connecting.authentication">
             <title>Authentication</title>
+
             <para>
-                The Google Calendar <acronym>API</acronym> allows access to both public and private calendar feeds.
-                Public feeds do not require authentication, but are read-only and offer reduced
-                functionality. Private feeds offers the most complete functionality but requires
-                an authenticated connection to the calendar servers. There are three authentication
-                schemes that are supported by Google Calendar:
+                The Google Calendar <acronym>API</acronym> allows access to both public and private
+                calendar feeds. Public feeds do not require authentication, but are read-only and
+                offer reduced functionality. Private feeds offers the most complete functionality
+                but requires an authenticated connection to the calendar servers. There are three
+                authentication schemes that are supported by Google Calendar:
             </para>
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -46,6 +56,7 @@
                         authentication schemes are insufficient.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>AuthSub</firstterm>
@@ -56,6 +67,7 @@
                         applications.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>MagicCookie</firstterm>
@@ -69,9 +81,9 @@
                     </para>
                 </listitem>
             </itemizedlist>
+
             <para>
-                The
-                <classname>Zend_Gdata</classname>
+                The <classname>Zend_Gdata</classname>
                 library provides support for all three authentication schemes.
                 The rest of this chapter will assume that you are familiar the
                 authentication schemes available and how to create an
@@ -83,26 +95,32 @@
                 Google Data <acronym>API</acronym> Developer's Guide</ulink>.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.calendar.connecting.service">
             <title>Creating A Service Instance</title>
+
             <para>
                 In order to interact with Google Calendar, this library provides the
-                <classname>Zend_Gdata_Calendar</classname> service class. This class provides a common
-                interface to the Google Data and Atom Publishing Protocol models and assists in
-                marshaling requests to and from the calendar servers.
+                <classname>Zend_Gdata_Calendar</classname> service class. This class provides a
+                common interface to the Google Data and Atom Publishing Protocol models and assists
+                in marshaling requests to and from the calendar servers.
             </para>
+
             <para>
                 Once deciding on an authentication scheme, the next step is to create an instance
-                of <classname>Zend_Gdata_Calendar</classname>. The class constructor takes an instance of
-                <classname>Zend_Http_Client</classname> as a single argument. This provides an interface for
-                AuthSub and ClientAuth authentication, as both of these require creation of a
-                special authenticated <acronym>HTTP</acronym> client. If no arguments are provided, an unauthenticated
-                instance of <classname>Zend_Http_Client</classname> will be automatically created.
+                of <classname>Zend_Gdata_Calendar</classname>. The class constructor takes an
+                instance of <classname>Zend_Http_Client</classname> as a single argument. This
+                provides an interface for AuthSub and ClientAuth authentication, as both of these
+                require creation of a special authenticated <acronym>HTTP</acronym> client. If no
+                arguments are provided, an unauthenticated instance of
+                <classname>Zend_Http_Client</classname> will be automatically created.
             </para>
+
             <para>
                 The example below shows how to create a Calendar service class using ClientAuth
                 authentication:
             </para>
+
             <programlisting language="php"><![CDATA[
 // Parameters for ClientAuth authentication
 $service = Zend_Gdata_Calendar::AUTH_SERVICE_NAME;
@@ -115,10 +133,12 @@ $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
 // Create an instance of the Calendar service
 $service = new Zend_Gdata_Calendar($client);
 ]]></programlisting>
+
             <para>
                 A Calendar service using AuthSub can be created in a similar, though slightly more
                 lengthy fashion:
             </para>
+
             <programlisting language="php"><![CDATA[
 /*
  * Retrieve the current URL so that the AuthSub server knows where to
@@ -206,30 +226,37 @@ session_start();
 // to the AuthSub server if necessary.
 $service = new Zend_Gdata_Calendar(getAuthSubHttpClient());
 ]]></programlisting>
+
             <para>
                 Finally, an unauthenticated server can be created for use with either public feeds
                 or MagicCookie authentication:
             </para>
+
             <programlisting language="php"><![CDATA[
 // Create an instance of the Calendar service using an unauthenticated
 // HTTP client
 
 $service = new Zend_Gdata_Calendar();
 ]]></programlisting>
+
             <para>
-                Note that MagicCookie authentication is not supplied with the <acronym>HTTP</acronym> connection, but
-                is instead specified along with the desired visibility when submitting queries. See
-                the section on retrieving events below for an example.
+                Note that MagicCookie authentication is not supplied with the
+                <acronym>HTTP</acronym> connection, but is instead specified along with the desired
+                visibility when submitting queries. See the section on retrieving events below for
+                an example.
             </para>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.calendar_retrieval">
         <title>Retrieving A Calendar List</title>
+
         <para>
             The calendar service supports retrieving a list of calendars for the authenticated
             user. This is the same list of calendars which are displayed in the Google Calendar
             UI, except those marked as "<code>hidden</code>" are also available.
         </para>
+
         <para>
             The calendar list is always private and must be accessed over an authenticated
             connection. It is not possible to retrieve another user's calendar list and it cannot
@@ -237,6 +264,7 @@ $service = new Zend_Gdata_Calendar();
             without holding appropriate credentials will fail and result in a 401 (Authentication
             Required) status code.
         </para>
+
         <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Calendar::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -248,13 +276,15 @@ try {
     echo "Error: " . $e->getMessage();
 }
 ]]></programlisting>
+
         <para>
             Calling <methodname>getCalendarListFeed()</methodname> creates a new instance of
-            <classname>Zend_Gdata_Calendar_ListFeed</classname> containing each available calendar as an
-            instance of <classname>Zend_Gdata_Calendar_ListEntry</classname>. After retrieving the feed, you
-            can use the iterator and accessors contained within the feed to inspect the enclosed
-            calendars.
+            <classname>Zend_Gdata_Calendar_ListFeed</classname> containing each available calendar
+            as an instance of <classname>Zend_Gdata_Calendar_ListEntry</classname>. After retrieving
+            the feed, you can use the iterator and accessors contained within the feed to inspect
+            the enclosed calendars.
         </para>
+
         <programlisting language="php"><![CDATA[
 echo "<h1>Calendar List Feed</h1>";
 echo "<ul>";
@@ -265,27 +295,33 @@ foreach ($listFeed as $calendar) {
 echo "</ul>";
 ]]></programlisting>
     </sect2>
+
     <sect2 id="zend.gdata.event_retrieval">
         <title>Retrieving Events</title>
+
         <para>
             Like the list of calendars, events are also retrieved using the
-            <classname>Zend_Gdata_Calendar</classname> service class. The event list returned is of type
-            <classname>Zend_Gdata_Calendar_EventFeed</classname> and contains each event as an instance of
-            <classname>Zend_Gdata_Calendar_EventEntry</classname>. As before, the iterator and accessors
-            contained within the event feed instance allow inspection of individual events.
+            <classname>Zend_Gdata_Calendar</classname> service class. The event list returned is of
+            type <classname>Zend_Gdata_Calendar_EventFeed</classname> and contains each event as an
+            instance of <classname>Zend_Gdata_Calendar_EventEntry</classname>. As before, the
+            iterator and accessors contained within the event feed instance allow inspection of
+            individual events.
         </para>
+
         <sect3 id="zend.gdata.event_retrieval.queries">
             <title>Queries</title>
+
             <para>
-                When retrieving events using the Calendar <acronym>API</acronym>, specially constructed query <acronym>URL</acronym>s are
-                used to describe what events should be returned. The
-                <classname>Zend_Gdata_Calendar_EventQuery</classname> class simplifies this task by
-                automatically constructing a query <acronym>URL</acronym> based on provided parameters. A full list of
-                these parameters is available at the <ulink
-                url="http://code.google.com/apis/gdata/reference.html#Queries">Queries section of
-                the Google Data <acronym>API</acronym>s Protocol Reference</ulink>. However, there are three
-                parameters that are worth special attention:
+                When retrieving events using the Calendar <acronym>API</acronym>, specially
+                constructed query <acronym>URL</acronym>s are used to describe what events should be
+                returned. The <classname>Zend_Gdata_Calendar_EventQuery</classname> class simplifies
+                this task by automatically constructing a query <acronym>URL</acronym> based on
+                provided parameters. A full list of these parameters is available at the <ulink
+                    url="http://code.google.com/apis/gdata/reference.html#Queries">Queries section
+                    of the Google Data <acronym>API</acronym>s Protocol Reference</ulink>. However,
+                there are three parameters that are worth special attention:
             </para>
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -297,6 +333,7 @@ echo "</ul>";
                         authenticated).
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Visibility</firstterm>
@@ -306,6 +343,7 @@ echo "</ul>";
                         will be available.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Projection</firstterm>
@@ -321,18 +359,21 @@ echo "</ul>";
                 </listitem>
             </itemizedlist>
         </sect3>
+
         <sect3 id="zend.gdata.event_retrieval.start_time">
             <title>Retrieving Events In Order Of Start Time</title>
+
             <para>
-                The example below illustrates the use of the <classname>Zend_Gdata_Query</classname> class
-                and specifies the private visibility feed, which requires that an authenticated
-                connection is available to the calendar servers. If a MagicCookie is being used for
-                authentication, the visibility should be instead set to
+                The example below illustrates the use of the <classname>Zend_Gdata_Query</classname>
+                class and specifies the private visibility feed, which requires that an
+                authenticated connection is available to the calendar servers. If a MagicCookie is
+                being used for authentication, the visibility should be instead set to
                 "<code>private-magicCookieValue</code>", where magicCookieValue is the random
-                string obtained when viewing the private <acronym>XML</acronym> address in the Google Calendar UI.
-                Events are requested chronologically by start time and only events occurring in the
-                future are returned.
+                string obtained when viewing the private <acronym>XML</acronym> address in the
+                Google Calendar UI. Events are requested chronologically by start time and only
+                events occurring in the future are returned.
             </para>
+
             <programlisting language="php"><![CDATA[
 $query = $service->newEventQuery();
 $query->setUser('default');
@@ -357,18 +398,21 @@ foreach ($eventFeed as $event) {
 }
 echo "</ul>";
 ]]></programlisting>
+
             <para>
                 Additional properties such as ID, author, when, event status, visibility, web
                 content, and content, among others are available within
                 <classname>Zend_Gdata_Calendar_EventEntry</classname>. Refer to the
-                <ulink url="http://framework.zend.com/apidoc/core/">Zend Framework <acronym>API</acronym>
-                Documentation</ulink> and the
+                <ulink url="http://framework.zend.com/apidoc/core/">Zend Framework
+                <acronym>API</acronym> Documentation</ulink> and the
                 <ulink url="http://code.google.com/apis/gdata/reference.html">Calendar Protocol
                 Reference</ulink> for a complete list.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.event_retrieval.date_range">
             <title>Retrieving Events In A Specified Date Range</title>
+
             <para>
                 To print out all events within a certain range, for example from December 1,
                 2006 through December 15, 2007, add the following two lines to the previous sample.
@@ -376,32 +420,40 @@ echo "</ul>";
                 <code>futureevents</code> will override <code>startMin</code> and
                 <code>startMax</code>.
             </para>
+
             <programlisting language="php"><![CDATA[
 $query->setStartMin('2006-12-01');
 $query->setStartMax('2006-12-16');
 ]]></programlisting>
+
             <para>
                 Note that <code>startMin</code> is inclusive whereas <code>startMax</code> is
                 exclusive. As a result, only events through 2006-12-15 23:59:59 will be returned.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.event_retrieval.fulltext">
             <title>Retrieving Events By Fulltext Query</title>
+
             <para>
                 To print out all events which contain a specific word, for example "dogfood", use
                 the <methodname>setQuery()</methodname> method when creating the query.
             </para>
+
             <programlisting language="php"><![CDATA[
 $query->setQuery("dogfood");
 ]]></programlisting>
         </sect3>
+
         <sect3 id="zend.gdata.event_retrieval.individual">
             <title>Retrieving Individual Events</title>
+
             <para>
                 Individual events can be retrieved by specifying their event ID as part of the
                 query. Instead of calling <methodname>getCalendarEventFeed()</methodname>,
                 <methodname>getCalendarEventEntry()</methodname> should be called instead.
             </para>
+
             <programlisting language="php"><![CDATA[
 $query = $service->newEventQuery();
 $query->setUser('default');
@@ -415,12 +467,14 @@ try {
     echo "Error: " . $e->getMessage();
 }
 ]]></programlisting>
+
             <para>
-                In a similar fashion, if the event <acronym>URL</acronym> is known, it can be passed directly into
-                <methodname>getCalendarEntry()</methodname> to retrieve a specific event. In this case, no
-                query object is required since the event <acronym>URL</acronym> contains all the necessary information
-                to retrieve the event.
+                In a similar fashion, if the event <acronym>URL</acronym> is known, it can be passed
+                directly into <methodname>getCalendarEntry()</methodname> to retrieve a specific
+                event. In this case, no query object is required since the event
+                <acronym>URL</acronym> contains all the necessary information to retrieve the event.
             </para>
+
             <programlisting language="php"><![CDATA[
 $eventURL = "http://www.google.com/calendar/feeds/default/private"
           . "/full/g829on5sq4ag12se91d10uumko";
@@ -433,19 +487,24 @@ try {
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.calendar.creating_events">
         <title>Creating Events</title>
+
         <sect3 id="zend.gdata.calendar.creating_events.single">
             <title>Creating Single-Occurrence Events</title>
+
             <para>
                 Events are added to a calendar by creating an instance of
-                <classname>Zend_Gdata_EventEntry</classname> and populating it with the appropriate data.
-                The calendar service instance (<classname>Zend_Gdata_Calendar</classname>) is then used to
-                used to transparently covert the event into <acronym>XML</acronym> and POST it to the calendar server.
-                Creating events requires either an AuthSub or ClientAuth authenticated connection
-                to the calendar server.
+                <classname>Zend_Gdata_EventEntry</classname> and populating it with the appropriate
+                data. The calendar service instance (<classname>Zend_Gdata_Calendar</classname>) is
+                then used to used to transparently covert the event into <acronym>XML</acronym> and
+                POST it to the calendar server. Creating events requires either an AuthSub or
+                ClientAuth authenticated connection to the calendar server.
             </para>
+
             <para>At a minimum, the following attributes should be set:</para>
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -454,6 +513,7 @@ try {
                         within the Google Calendar UI.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>When</firstterm>
@@ -463,7 +523,9 @@ try {
                     </para>
                 </listitem>
             </itemizedlist>
+
             <para>Other useful attributes that may optionally set include:</para>
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -472,6 +534,7 @@ try {
                         event.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Content</firstterm>
@@ -480,6 +543,7 @@ try {
                         within Google Calendar.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>EventStatus</firstterm>
@@ -487,12 +551,14 @@ try {
                         canceled.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Hidden</firstterm>
                         removes the event from the Google Calendar UI.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Transparency</firstterm>
@@ -500,6 +566,7 @@ try {
                         the user's free/busy list.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>WebContent</firstterm>
@@ -507,12 +574,14 @@ try {
                         an event.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Where</firstterm>
                         indicates the location of the event.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>Visibility</firstterm>
@@ -521,21 +590,25 @@ try {
                     </para>
                 </listitem>
             </itemizedlist>
+
             <para>
-                For a complete list of event attributes, refer to the
-                <ulink url="http://framework.zend.com/apidoc/core/">Zend Framework <acronym>API</acronym>
-                Documentation</ulink> and the
-                <ulink url="http://code.google.com/apis/gdata/reference.html">Calendar Protocol
-                Reference</ulink>. Attributes that can contain multiple values, such as where, are
-                implemented as arrays and need to be created accordingly. Be aware that all of
+                For a complete list of event attributes, refer to the <ulink
+                    url="http://framework.zend.com/apidoc/core/">Zend Framework
+                    <acronym>API</acronym> Documentation</ulink> and the <ulink
+                    url="http://code.google.com/apis/gdata/reference.html">Calendar Protocol
+                    Reference</ulink>. Attributes that can contain multiple values, such as where,
+                are implemented as arrays and need to be created accordingly. Be aware that all of
                 these attributes require objects as parameters. Trying instead to populate them
-                using strings or primitives will result in errors during conversion to <acronym>XML</acronym>.
+                using strings or primitives will result in errors during conversion to
+                <acronym>XML</acronym>.
             </para>
+
             <para>
                 Once the event has been populated, it can be uploaded to the calendar server by
-                passing it as an argument to the calendar service's <methodname>insertEvent()</methodname>
-                function.
+                passing it as an argument to the calendar service's
+                <methodname>insertEvent()</methodname> function.
             </para>
+
             <programlisting language="php"><![CDATA[
 // Create a new entry using the calendar service's magic factory method
 $event= $service->newEventEntry();
@@ -564,8 +637,10 @@ $event->when = array($when);
 $newEvent = $service->insertEvent($event);
 ]]></programlisting>
         </sect3>
+
         <sect3 id="zend.gdata.calendar.creating_events.schedulers_reminders">
             <title>Event Schedules and Reminders</title>
+
             <para>
                 An event's starting time and duration are determined by the value of its
                 <code>when</code> property, which contains the properties
@@ -573,6 +648,7 @@ $newEvent = $service->insertEvent($event);
                 <code>StartTime</code> and <code>EndTime</code> control the duration of the
                 event, while the <code>valueString</code> property is currently unused.
             </para>
+
             <para>
                 All-day events can be scheduled by specifying only the date omitting the time when
                 setting <code>startTime</code> and <code>endTime</code>. Likewise, zero-duration
@@ -580,6 +656,7 @@ $newEvent = $service->insertEvent($event);
                 date/time values should be provided in
                 <ulink url="http://www.ietf.org/rfc/rfc3339.txt">RFC3339</ulink> format.
             </para>
+
             <programlisting language="php"><![CDATA[
 // Schedule the event to occur on December 05, 2007 at 2 PM PST (UTC-8)
 // with a duration of one hour.
@@ -590,11 +667,13 @@ $when->endTime="2007-12-05T15:00:00:00-08:00";
 // Apply the when property to an event
 $event->when = array($when);
 ]]></programlisting>
+
             <para>
                 The <code>when</code> attribute also controls when reminders are sent to a user.
                 Reminders are stored in an array and each event may have up to find reminders
                 associated with it.
             </para>
+
             <para>
                 For a <code>reminder</code> to be valid, it needs to have two attributes set:
                 <code>method</code> and a time. <code>Method</code> can accept one of the following
@@ -605,6 +684,7 @@ $event->when = array($when);
                 precise unit available. For example, 1 hour and 30 minutes should be entered as 90
                 minutes.
             </para>
+
             <programlisting language="php"><![CDATA[
 // Create a new reminder object. It should be set to send an email
 // to the user 10 minutes beforehand.
@@ -617,8 +697,10 @@ $when = $event->when[0];
 $when->reminders = array($reminder);
 ]]></programlisting>
         </sect3>
+
         <sect3 id="zend.gdata.calendar.creating_events.recurring">
             <title>Creating Recurring Events</title>
+
             <para>
                 Recurring events are created the same way as single-occurrence events, except a
                 recurrence attribute should be provided instead of a where attribute. The
@@ -626,19 +708,23 @@ $when->reminders = array($reminder);
                 using properties defined in the iCalendar standard (<ulink
                 url="http://www.ietf.org/rfc/rfc2445.txt">RFC 2445</ulink>).
             </para>
+
             <para>
                 Exceptions to the recurrence pattern will usually be specified by a distinct
                 <code>recurrenceException</code> attribute. However, the iCalendar standard
                 provides a secondary format for defining recurrences, and the possibility that
                 either may be used must be accounted for.
             </para>
+
             <para>
                 Due to the complexity of parsing recurrence patterns, further information on this
                 them is outside the scope of this document. However, more information can be found
-                in the <ulink url="http://code.google.com/apis/gdata/elements.html#gdRecurrence">
-                Common Elements section of the Google Data <acronym>API</acronym>s Developer Guide</ulink>, as well as
-                in <acronym>RFC</acronym> 2445.
+                in the <ulink
+                    url="http://code.google.com/apis/gdata/elements.html#gdRecurrence">Common
+                    Elements section of the Google Data <acronym>API</acronym>s Developer
+                    Guide</ulink>, as well as in <acronym>RFC</acronym> 2445.
             </para>
+
             <programlisting language="php"><![CDATA[
  // Create a new entry using the calendar service's magic factory method
 $event= $service->newEventEntry();
@@ -665,8 +751,10 @@ $event->recurrence = $service->newRecurrence($recurrence);
 $newEvent = $service->insertEvent($event);
 ]]></programlisting>
         </sect3>
+
         <sect3 id="zend.gdata.calendar.creating_events.quickadd">
             <title>Using QuickAdd</title>
+
             <para>
                 QuickAdd is a feature which allows events to be created using free-form text entry.
                 For example, the string "Dinner at Joe's Diner on Thursday" would create an event
@@ -675,6 +763,7 @@ $newEvent = $service->insertEvent($event);
                 <constant>TRUE</constant> and store the freeform text as a <code>content</code>
                 property.
             </para>
+
             <programlisting language="php"><![CDATA[
 // Create a new entry using the calendar service's magic factory method
 $event= $service->newEventEntry();
@@ -689,20 +778,25 @@ $newEvent = $service->insertEvent($event);
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.calendar.modifying_events">
         <title>Modifying Events</title>
+
         <para>
             Once an instance of an event has been obtained, the event's attributes can be locally
             modified in the same way as when creating an event. Once all modifications are
-            complete, calling the event's <methodname>save()</methodname> method will upload the changes to the
-            calendar server and return a copy of the event as it was created on the server.
+            complete, calling the event's <methodname>save()</methodname> method will upload the
+            changes to the calendar server and return a copy of the event as it was created on the
+            server.
         </para>
+
         <para>
             In the event another user has modified the event since the local copy was retrieved,
-            <methodname>save()</methodname> will fail and the server will return a 409 (Conflict) status code.
-            To resolve this a fresh copy of the event must be retrieved from the server before
-            attempting to resubmit any modifications.
+            <methodname>save()</methodname> will fail and the server will return a 409 (Conflict)
+            status code. To resolve this a fresh copy of the event must be retrieved from the server
+            before attempting to resubmit any modifications.
         </para>
+
         <programlisting language="php"><![CDATA[
 // Get the first event in the user's event list
 $event = $eventFeed[0];
@@ -718,36 +812,45 @@ try {
 }
 ]]></programlisting>
     </sect2>
+
     <sect2 id="zend.gdata.calendar.deleting_events">
         <title>Deleting Events</title>
+
         <para>
             Calendar events can be deleted either by calling the calendar service's
-            <methodname>delete()</methodname> method and providing the edit <acronym>URL</acronym> of an event or by calling an
-            existing event's own <methodname>delete()</methodname> method.
+            <methodname>delete()</methodname> method and providing the edit <acronym>URL</acronym>
+            of an event or by calling an existing event's own <methodname>delete()</methodname>
+            method.
         </para>
+
         <para>
             In either case, the deleted event will still show up on a user's private event feed if
             an <code>updateMin</code> query parameter is provided. Deleted events can be
             distinguished from regular events because they will have their <code>eventStatus</code>
             property set to "http://schemas.google.com/g/2005#event.canceled".
         </para>
+
         <programlisting language="php"><![CDATA[
 // Option 1: Events can be deleted directly
 $event->delete();
 ]]></programlisting>
+
         <programlisting language="php"><![CDATA[
 // Option 2: Events can be deleted supplying the edit URL of the event
 // to the calendar service, if known
 $service->delete($event->getEditLink()->href);
 ]]></programlisting>
     </sect2>
+
     <sect2 id="zend.gdata.calendar.comments">
         <title>Accessing Event Comments</title>
+
         <para>
             When using the full event view, comments are not directly stored within an entry.
-            Instead, each event contains a <acronym>URL</acronym> to its associated comment feed which must be
-            manually requested.
+            Instead, each event contains a <acronym>URL</acronym> to its associated comment feed
+            which must be manually requested.
         </para>
+
         <para>
             Working with comments is fundamentally similar to working with events, with the only
             significant difference being that a different feed and event class should be used and
@@ -755,6 +858,7 @@ $service->delete($event->getEditLink()->href);
             comments. Specifically, the comment's author is stored in the <code>author</code>
             property, and the comment text is stored in the <code>content</code> property.
         </para>
+
         <programlisting language="php"><![CDATA[
 // Extract the comment URL from the first event in a user's feed list
 $event = $eventFeed[0];

+ 12 - 15
documentation/manual/en/module_specs/Zend_Gdata_ClientLogin.xml

@@ -10,8 +10,8 @@
     </para>
 
     <para>
-        See
-        <ulink url="http://code.google.com/apis/accounts/AuthForInstalledApps.html"> http://code.google.com/apis/accounts/AuthForInstalledApps.html </ulink>
+        See <ulink
+            url="http://code.google.com/apis/accounts/AuthForInstalledApps.html"> http://code.google.com/apis/accounts/AuthForInstalledApps.html </ulink>
         for more information about Google Data ClientLogin authentication.
     </para>
 
@@ -64,19 +64,19 @@
         </para>
 
         <para>
-          The optional sixth parameter is a string ID for a
-          <trademark>CAPTCHA</trademark> challenge that has been issued by
-          the server. It is only necessary when logging in after receiving
-          a <trademark>CAPTCHA</trademark> challenge from a previous
-          login attempt.
+            The optional sixth parameter is a string ID for a
+            <trademark>CAPTCHA</trademark> challenge that has been issued by
+            the server. It is only necessary when logging in after receiving
+            a <trademark>CAPTCHA</trademark> challenge from a previous
+            login attempt.
         </para>
 
         <para>
-          The optional seventh parameter is a user's response to a
-          <trademark>CAPTCHA</trademark> challenge that has been issued by
-          the server. It is only necessary when logging in after receiving
-          a <trademark>CAPTCHA</trademark> challenge from a previous
-          login attempt.
+            The optional seventh parameter is a user's response to a
+            <trademark>CAPTCHA</trademark> challenge that has been issued by
+            the server. It is only necessary when logging in after receiving
+            a <trademark>CAPTCHA</trademark> challenge from a previous
+            login attempt.
         </para>
 
         <para>
@@ -101,7 +101,6 @@ try {
 
 $cal = new Zend_Gdata_Calendar($client);
 ]]></programlisting>
-
     </sect2>
 
     <sect2 id="zend.gdata.clientlogin.terminating">
@@ -114,7 +113,5 @@ $cal = new Zend_Gdata_Calendar($client);
             to a Google account, and therefore these can be used repeatedly
             in the future.
         </para>
-
     </sect2>
-
 </sect1>

+ 17 - 8
documentation/manual/en/module_specs/Zend_Gdata_Docs.xml

@@ -12,13 +12,14 @@
     </para>
 
     <para>
-        See
-        <ulink url="http://code.google.com/apis/documents/overview.html">http://code.google.com/apis/documents/overview.html</ulink>
+        See <ulink
+            url="http://code.google.com/apis/documents/overview.html">http://code.google.com/apis/documents/overview.html</ulink>
         for more information about the Google Documents List <acronym>API</acronym>.
     </para>
 
     <sect2 id="zend.gdata.docs.listdocuments">
         <title>Get a List of Documents</title>
+
         <para>
             You can get a list of the Google Documents for a particular user by using
             the <methodname>getDocumentListFeed()</methodname> method of the docs
@@ -46,6 +47,7 @@ $feed = $docs->getDocumentListFeed();
 
     <sect2 id="zend.gdata.docs.creating">
         <title>Upload a Document</title>
+
         <para>
             You can create a new Google Document by uploading a word
             processing document, spreadsheet, or presentation. This example
@@ -53,6 +55,7 @@ $feed = $docs->getDocumentListFeed();
             library. It demonstrates uploading a file and printing
             information about the result from the server.
         </para>
+
         <programlisting language="php"><![CDATA[
 /**
  * Upload the specified document
@@ -105,6 +108,7 @@ function uploadDocument($docs, $html, $originalFileName,
 
     <sect2 id="zend.gdata.docs.queries">
         <title>Searching the documents feed</title>
+
         <para>
             You can search the Document List using some of the <ulink
             url="http://code.google.com/apis/gdata/reference.html#Queries">standard
@@ -114,13 +118,17 @@ function uploadDocument($docs, $html, $originalFileName,
             The full-text query string is used to search the content of all
             the documents. More detailed information on parameters specific
             to the Documents List can be found in the <ulink
-            url="http://code.google.com/apis/documents/reference.html#Parameters">Documents List Data <acronym>API</acronym> Reference Guide</ulink>.
+                url="http://code.google.com/apis/documents/reference.html#Parameters">Documents List
+                Data <acronym>API</acronym> Reference Guide</ulink>.
         </para>
 
         <sect3 id="zend.gdata.docs.listwpdocuments">
             <title>Get a List of Word Processing Documents</title>
+
             <para>
-                You can also request a feed containing all of your documents of a specific type. For example, to see a list of your work processing documents, you would perform a category query as follows.
+                You can also request a feed containing all of your documents of a specific type. For
+                example, to see a list of your work processing documents, you would perform a
+                category query as follows.
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -131,6 +139,7 @@ $feed = $docs->getDocumentListFeed(
 
         <sect3 id="zend.gdata.docs.listspreadsheets">
             <title>Get a List of Spreadsheets</title>
+
             <para>
                 To request a list of your Google Spreadsheets, use the following category query:
             </para>
@@ -143,20 +152,20 @@ $feed = $docs->getDocumentListFeed(
 
         <sect3 id="zend.gdata.docs.textquery">
             <title>Performing a text query</title>
+
             <para>
                 You can search the content of documents by using a
                 <classname>Zend_Gdata_Docs_Query</classname> in your request. A Query object
-                can be used to construct the query <acronym>URI</acronym>, with the search term being
-                passed in as a parameter. Here is an example method which queries
+                can be used to construct the query <acronym>URI</acronym>, with the search term
+                being passed in as a parameter. Here is an example method which queries
                 the documents list for documents which contain the search string:
             </para>
+
             <programlisting language="php"><![CDATA[
 $docsQuery = new Zend_Gdata_Docs_Query();
 $docsQuery->setQuery($query);
 $feed = $client->getDocumentListFeed($docsQuery);
 ]]></programlisting>
         </sect3>
-
     </sect2>
-
 </sect1>

+ 23 - 19
documentation/manual/en/module_specs/Zend_Gdata_Exception.xml

@@ -6,7 +6,8 @@
     <para>
         The <classname>Zend_Gdata_App_Exception</classname> class is a base class
         for exceptions thrown by <classname>Zend_Gdata</classname>. You can catch any exception
-        thrown by <classname>Zend_Gdata</classname> by catching <classname>Zend_Gdata_App_Exception</classname>.
+        thrown by <classname>Zend_Gdata</classname> by catching
+        <classname>Zend_Gdata_App_Exception</classname>.
     </para>
 
     <programlisting language="php"><![CDATA[
@@ -29,6 +30,7 @@ try {
                     indicates that the user's account credentials were not valid.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <classname>Zend_Gdata_App_BadMethodCallException</classname>
@@ -37,6 +39,7 @@ try {
                     the CodeSearch service does not support <methodname>post()</methodname>.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <classname>Zend_Gdata_App_HttpException</classname>
@@ -47,6 +50,7 @@ try {
                     enough details.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <classname>Zend_Gdata_App_InvalidArgumentException</classname>
@@ -56,25 +60,26 @@ try {
                     or fetching a Blogger feed without specifying
                     any blog name.
                 </para>
-              </listitem>
-              <listitem>
+            </listitem>
+
+            <listitem>
                 <para>
-                  <classname>Zend_Gdata_App_CaptchaRequiredException</classname>
-                  is thrown when a ClientLogin attempt receives a
-                  <trademark>CAPTCHA</trademark> challenge from the
-                  authentication service. This exception contains a token
-                  ID and a <acronym>URL</acronym> to a <trademark>CAPTCHA</trademark>
-                  challenge image. The image is a visual puzzle that
-                  should be displayed to the user. After
-                  collecting the user's response to the challenge
-                  image, the response can be included with the next
-                  ClientLogin attempt.The user can alternatively be
-                  directed to this website:
-                  <ulink url="https://www.google.com/accounts/DisplayUnlockCaptcha"/>
-                  Further information can be found in the
-                  <link linkend="zend.gdata.clientlogin">ClientLogin documentation</link>.
+                    <classname>Zend_Gdata_App_CaptchaRequiredException</classname>
+                    is thrown when a ClientLogin attempt receives a
+                    <trademark>CAPTCHA</trademark> challenge from the
+                    authentication service. This exception contains a token
+                    ID and a <acronym>URL</acronym> to a <trademark>CAPTCHA</trademark>
+                    challenge image. The image is a visual puzzle that
+                    should be displayed to the user. After
+                    collecting the user's response to the challenge
+                    image, the response can be included with the next
+                    ClientLogin attempt.The user can alternatively be
+                    directed to this website:
+                    <ulink url="https://www.google.com/accounts/DisplayUnlockCaptcha"/>
+                    Further information can be found in the
+                    <link linkend="zend.gdata.clientlogin">ClientLogin documentation</link>.
                 </para>
-              </listitem>
+            </listitem>
         </itemizedlist>
     </para>
 
@@ -97,5 +102,4 @@ try {
     // Google Data servers cannot be contacted.
     die($httpEx->getMessage);}
 ]]></programlisting>
-
 </sect1>

+ 15 - 43
documentation/manual/en/module_specs/Zend_Gdata_Gapps.xml

@@ -22,17 +22,18 @@
     <para>
         For more information on the Google Apps Provisioning <acronym>API</acronym>, including
         instructions for enabling <acronym>API</acronym> access, refer to the <ulink
-        url="http://code.google.com/apis/apps/gdata_provisioning_api_v2.0_reference.html">Provisioning
-        <acronym>API</acronym> V2.0 Reference</ulink>.
+            url="http://code.google.com/apis/apps/gdata_provisioning_api_v2.0_reference.html">Provisioning
+            <acronym>API</acronym> V2.0 Reference</ulink>.
     </para>
 
     <note>
         <title>Authentication</title>
+
         <para>
             The Provisioning <acronym>API</acronym> does not support authentication via AuthSub
             and anonymous access is not permitted. All <acronym>HTTP</acronym> connections must
             be authenticated using ClientAuth authentication.
-            </para>
+        </para>
     </note>
 
     <sect2 id="zend.gdata.gapps.domain">
@@ -59,7 +60,6 @@
 $domain = "example.com";
 $gdata = new Zend_Gdata_Gapps($client, $domain);
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.domain.query">
@@ -89,9 +89,7 @@ $domain = "example.com";
 $gdata = new Zend_Gdata_Gapps($client, $domain);
 $query = $gdata->newUserQuery($arg);
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.gapps.users">
@@ -139,7 +137,6 @@ $user = $gdata->insertUser($user);
                 Optionally, the password can be provided as an SHA-1 digest if
                 <code>login->passwordHashFunction</code> is set to 'SHA-1'.
             </para>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.users.retrieving">
@@ -195,7 +192,6 @@ echo 'Has Agreed To Terms: ' .
                 ServiceExceptions will be covered in <xref
                 linkend="zend.gdata.gapps.exceptions" />.
             </para>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.users.retrievingAll">
@@ -236,7 +232,6 @@ foreach ($feed as $user) {
         ' ' . $user->name->familyName . ")\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.users.updating">
@@ -275,7 +270,6 @@ $user = $user->save();
                     manner as stored passwords are not made available via the
                     Provisioning <acronym>API</acronym> for security reasons.
                 </para>
-
             </sect4>
 
             <sect4 id="zend.gdata.gapps.users.updating.forcingPasswordChange">
@@ -299,7 +293,6 @@ $user = $user->save();
                     <code>login->changePasswordAtNextLogin</code> property to
                     <constant>FALSE</constant>.
                 </para>
-
             </sect4>
 
             <sect4 id="zend.gdata.gapps.users.updating.suspendingAccount">
@@ -310,8 +303,8 @@ $user = $user->save();
                     their user account by instead
                     <emphasis>suspending</emphasis> their user account.
                     Accounts can be suspended or restored by using the
-                    <methodname>suspendUser()</methodname> and <methodname>restoreUser()</methodname>
-                    convenience methods:
+                    <methodname>suspendUser()</methodname> and
+                    <methodname>restoreUser()</methodname> convenience methods:
                 </para>
 
                 <programlisting language="php"><![CDATA[
@@ -336,7 +329,6 @@ $user = $user->save();
                     <code>login->suspended</code> property to
                     <constant>FALSE</constant>.
                 </para>
-
             </sect4>
 
             <sect4 id="zend.gdata.gapps.users.updating.grantingAdminRights">
@@ -359,9 +351,7 @@ $user = $user->save();
                     property to <constant>FALSE</constant> revokes their
                     administrative rights.
                 </para>
-
             </sect4>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.users.deleting">
@@ -386,9 +376,7 @@ $user->delete();
             <programlisting language="php"><![CDATA[
 $gdata->deleteUser('foo');
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.gapps.nicknames">
@@ -431,7 +419,6 @@ $nickname->login = $gdata->newLogin('foo');
 $nickname->nickname = $gdata->newNickname('bar');
 $nickname = $gdata->insertNickname($nickname);
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.nicknames.retrieving">
@@ -473,7 +460,6 @@ echo 'Owner: ' . $nickname->login->username . "\n";
                 will be discussed in <xref linkend="zend.gdata.gapps.exceptions"
                 />.
             </para>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.nicknames.retrievingUser">
@@ -513,11 +499,11 @@ foreach ($feed as $nickname) {
     echo '  * ' . $nickname->nickname->name . "\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.nicknames.retrievingAll">
             <title>Retrieving all nicknames in a domain</title>
+
             <para>
                 To retrieve all nicknames in a feed, simply call the
                 convenience method <methodname>retrieveAllNicknames()</methodname>
@@ -550,7 +536,6 @@ foreach ($feed as $nickname) {
         $nickname->login->username . "\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.nicknames.deleting">
@@ -575,9 +560,7 @@ $nickname->delete();
             <programlisting language="php"><![CDATA[
 $gdata->deleteNickname('bar');
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.gapps.emailLists">
@@ -619,12 +602,10 @@ $list = $gdata->newEmailListEntry();
 $list->emailList = $gdata->newEmailList('friends');
 $list = $gdata->insertEmailList($list);
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.emailList.retrieve">
-            <title>Retrieving all email lists to which a recipient is
-            subscribed</title>
+            <title>Retrieving all email lists to which a recipient is subscribed</title>
 
             <para>
                 To retrieve all email lists to which a particular recipient is
@@ -641,8 +622,8 @@ foreach ($feed as $list) {
 ]]></programlisting>
 
             <para>
-                This will create a <classname>Zend_Gdata_Gapps_EmailListFeed</classname> object which
-                holds each email list associated with the specified recipient.
+                This will create a <classname>Zend_Gdata_Gapps_EmailListFeed</classname> object
+                which holds each email list associated with the specified recipient.
             </para>
 
             <para>
@@ -661,7 +642,6 @@ foreach ($feed as $list) {
     echo '  * ' . $list->emailList->name . "\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.emailLists.retrievingAll">
@@ -681,8 +661,8 @@ foreach ($feed as $list) {
 ]]></programlisting>
 
             <para>
-                This will create a <classname>Zend_Gdata_Gapps_EmailListFeed</classname> object which
-                holds each email list on the domain.
+                This will create a <classname>Zend_Gdata_Gapps_EmailListFeed</classname> object
+                which holds each email list on the domain.
             </para>
 
             <para>
@@ -697,7 +677,6 @@ foreach ($feed as $list) {
     echo '  * ' . $list->emailList->name . "\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.emailList.deleting">
@@ -711,9 +690,7 @@ foreach ($feed as $list) {
             <programlisting language="php"><![CDATA[
 $gdata->deleteEmailList('friends');
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.gapps.emailListRecipients">
@@ -737,7 +714,6 @@ $gdata->deleteEmailList('friends');
             <programlisting language="php"><![CDATA[
 $gdata->addRecipientToEmailList('bar@somewhere.com', 'friends');
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.emailListRecipients.retrieving">
@@ -777,7 +753,6 @@ foreach ($feed as $recipient) {
                 This will create a <classname>Zend_Gdata_Gapps_EmailListRecipientFeed</classname>
                 object which holds each recipient for the selected email list.
             </para>
-
         </sect3>
 
         <sect3 id="zend.gdata.gapps.emailListRecipients.removing">
@@ -792,9 +767,7 @@ foreach ($feed as $recipient) {
             <programlisting language="php"><![CDATA[
 $gdata->removeRecipientFromEmailList('baz@somewhere.com', 'friends');
 ]]></programlisting>
-
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.gapps.exceptions">
@@ -802,7 +775,8 @@ $gdata->removeRecipientFromEmailList('baz@somewhere.com', 'friends');
 
         <para>
             In addition to the standard suite of exceptions thrown by
-            <classname>Zend_Gdata</classname>, requests using the Provisioning <acronym>API</acronym> may also throw a
+            <classname>Zend_Gdata</classname>, requests using the Provisioning
+            <acronym>API</acronym> may also throw a
             <classname>Zend_Gdata_Gapps_ServiceException</classname>. These exceptions
             indicate that a <acronym>API</acronym> specific error occurred which prevents the
             request from completing.
@@ -815,7 +789,7 @@ $gdata->removeRecipientFromEmailList('baz@somewhere.com', 'friends');
             list of known error codes is provided in the Zend Framework <acronym>API</acronym>
             documentation under <classname>Zend_Gdata_Gapps_Error</classname>. Additionally, the
             authoritative error list is available online at <ulink
-            url="http://code.google.com/apis/apps/gdata_provisioning_api_v2.0_reference.html#appendix_d">Google
+                url="http://code.google.com/apis/apps/gdata_provisioning_api_v2.0_reference.html#appendix_d">Google
             Apps Provisioning <acronym>API</acronym> V2.0 Reference: Appendix D</ulink>.
         </para>
 
@@ -848,7 +822,5 @@ function retrieveUser ($username) {
     return $user;
 }
 ]]></programlisting>
-
     </sect2>
-
 </sect1>

+ 146 - 43
documentation/manual/en/module_specs/Zend_Gdata_Gbase.xml

@@ -2,14 +2,18 @@
 <!-- Reviewed: no -->
 <sect1 id="zend.gdata.gbase">
     <title>Using Google Base</title>
+
     <para>
-        The Google Base data <acronym>API</acronym> is designed to enable developers to do two things:
+        The Google Base data <acronym>API</acronym> is designed to enable developers to do two
+        things:
+
         <itemizedlist>
             <listitem>
                 <para>
                     Query Google Base data to create applications and mashups.
                 </para>
-                </listitem>
+            </listitem>
+
             <listitem>
                 <para>
                     Input and manage Google Base items programmatically.
@@ -17,67 +21,105 @@
             </listitem>
         </itemizedlist>
     </para>
+
     <para>
-        There are two item feeds: snippets feed and customer items feeds. The snippets feed contains all Google Base data and is available to anyone to query against without a need for authentication. The customer items feed is a customer-specific subset of data and only a customer/owner can access this feed to insert, update, or delete their own data. Queries are constructed the same way against both types of feeds.
+        There are two item feeds: snippets feed and customer items feeds. The snippets feed contains
+        all Google Base data and is available to anyone to query against without a need for
+        authentication. The customer items feed is a customer-specific subset of data and only a
+        customer/owner can access this feed to insert, update, or delete their own data. Queries are
+        constructed the same way against both types of feeds.
     </para>
+
     <para>
         See <ulink url="http://code.google.com/apis/base/">http://code.google.com/apis/base</ulink>
         for more information about the Google Base <acronym>API</acronym>.
     </para>
+
     <sect2 id="zend.gdata.gbase.connect">
         <title>Connect To The Base Service</title>
+
         <para>
-            The Google Base <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is based off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based format for managing web-based resources. Traffic between a client and the Google Base servers occurs over <acronym>HTTP</acronym> and allows for both authenticated and unauthenticated connections.
+            The Google Base <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is based
+            off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based format for
+            managing web-based resources. Traffic between a client and the Google Base servers
+            occurs over <acronym>HTTP</acronym> and allows for both authenticated and
+            unauthenticated connections.
         </para>
+
         <para>
-            Before any transactions can occur, this connection needs to be made. Creating a connection to the base servers involves two steps: creating an <acronym>HTTP</acronym> client and binding a
-            <classname>Zend_Gdata_Gbase</classname> service instance to that client.
+            Before any transactions can occur, this connection needs to be made. Creating a
+            connection to the base servers involves two steps: creating an <acronym>HTTP</acronym>
+            client and binding a <classname>Zend_Gdata_Gbase</classname> service instance to that
+            client.
         </para>
+
         <sect3 id="zend.gdata.gbase.connect.authentication">
             <title>Authentication</title>
+
             <para>
-                The Google Base <acronym>API</acronym> allows access to both public and private base feeds. Public feeds do not require authentication, but are read-only and offer reduced functionality. Private feeds offers the most complete functionality but requires an authenticated connection to the base servers. There are three authentication schemes that are supported by Google Base:
+                The Google Base <acronym>API</acronym> allows access to both public and private base
+                feeds. Public feeds do not require authentication, but are read-only and offer
+                reduced functionality. Private feeds offers the most complete functionality but
+                requires an authenticated connection to the base servers. There are three
+                authentication schemes that are supported by Google Base:
             </para>
+
             <itemizedlist>
                 <listitem>
                     <para>
-                        <firstterm>ClientAuth</firstterm>
-                        provides direct username/password authentication to the base servers. Since this scheme requires that users provide your application with their password, this authentication is only recommended when other authentication schemes are insufficient.
+                        <firstterm>ClientAuth</firstterm> provides direct username/password
+                        authentication to the base servers. Since this scheme requires that users
+                        provide your application with their password, this authentication is only
+                        recommended when other authentication schemes are insufficient.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <firstterm>AuthSub</firstterm>
-                        allows authentication to the base servers via a Google proxy server. This provides the same level of convenience as ClientAuth but without the security risk, making this an ideal choice for web-based applications.
+                        <firstterm>AuthSub</firstterm> allows authentication to the base servers via
+                        a Google proxy server. This provides the same level of convenience as
+                        ClientAuth but without the security risk, making this an ideal choice for
+                         web-based applications.
                     </para>
                 </listitem>
             </itemizedlist>
+
             <para>
-                The <classname>Zend_Gdata</classname>
-                library provides support for all three authentication schemes. The rest of this chapter will assume that you are familiar the authentication schemes available and how to create an appropriate authenticated connection. For more information, please see section <xref linkend="zend.gdata.introduction.authentication" />.
-                or the
-                <ulink url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the Google Data <acronym>API</acronym> Developer's Guide</ulink>.
+                The <classname>Zend_Gdata</classname> library provides support for all three
+                authentication schemes. The rest of this chapter will assume that you are familiar
+                the authentication schemes available and how to create an appropriate authenticated
+                connection. For more information, please see section <xref
+                    linkend="zend.gdata.introduction.authentication" /> or the <ulink
+                    url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the
+                    Google Data <acronym>API</acronym> Developer's Guide</ulink>.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.gbase.connect.service">
             <title>Create A Service Instance</title>
+
             <para>
                 In order to interact with Google Base, this library provides the
-                <classname>Zend_Gdata_Gbase</classname>
-                service class. This class provides a common interface to the Google Data and Atom Publishing Protocol models and assists in marshaling requests to and from the base servers.
+                <classname>Zend_Gdata_Gbase</classname> service class. This class provides a common
+                interface to the Google Data and Atom Publishing Protocol models and assists in
+                marshaling requests to and from the base servers.
             </para>
+
             <para>
                 Once deciding on an authentication scheme, the next step is to create an instance of
-                <classname>Zend_Gdata_Gbase</classname>
-                . This class takes in an instance of
-                <classname>Zend_Http_Client</classname>
-                as a single argument. This provides an interface for AuthSub and ClientAuth authentication, as both of these creation of a special authenticated <acronym>HTTP</acronym> client. If no arguments are provided, an unauthenticated instance of
-                <classname>Zend_Http_Client</classname>
+                <classname>Zend_Gdata_Gbase</classname>. This class takes in an instance of
+                <classname>Zend_Http_Client</classname> as a single argument. This provides an
+                interface for AuthSub and ClientAuth authentication, as both of these creation of a
+                special authenticated <acronym>HTTP</acronym> client. If no arguments are provided,
+                an unauthenticated instance of <classname>Zend_Http_Client</classname>
                 will be automatically created.
             </para>
+
             <para>
-                The example below shows how to create a Base service class using ClientAuth authentication:
+                The example below shows how to create a Base service class using ClientAuth
+                authentication:
             </para>
+
             <programlisting language="php"><![CDATA[
 // Parameters for ClientAuth authentication
 $service = Zend_Gdata_Gbase::AUTH_SERVICE_NAME;
@@ -90,8 +132,13 @@ $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
 // Create an instance of the Base service
 $service = new Zend_Gdata_Gbase($client);
 ]]></programlisting>
-<para>A Base service using AuthSub can be created in a similar, though slightly more lengthy fashion:</para>
-<programlisting language="php"><![CDATA[
+
+            <para>
+                A Base service using AuthSub can be created in a similar, though slightly more
+                lengthy fashion:
+            </para>
+
+            <programlisting language="php"><![CDATA[
 /*
  * Retrieve the current URL so that the AuthSub server knows where to
  * redirect the user after authentication is complete.
@@ -186,28 +233,41 @@ $service = new Zend_Gdata_Gbase();
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.gbase.retrieve">
         <title>Retrieve Items</title>
+
         <para>
-            You can query customer items feed or snippets feed to retrieve items. It involves two steps, sending a query and iterating through the returned feed.
+            You can query customer items feed or snippets feed to retrieve items. It involves two
+            steps, sending a query and iterating through the returned feed.
         </para>
+
         <sect3 id="zend.gdata.gbase.retrieve.query">
             <title>Send a Structured Query</title>
+
             <para>
-                You can send a structured query to retrieve items from your own customer items feed or from the public snippets feed.
+                You can send a structured query to retrieve items from your own customer items feed
+                or from the public snippets feed.
             </para>
+
             <para>
-                When retrieving items using the Base <acronym>API</acronym>, specially constructed query <acronym>URL</acronym>s are used
-                to describe what events should be returned. The
-                <classname>Zend_Gdata_Gbase_ItemQuery</classname> and
+                When retrieving items using the Base <acronym>API</acronym>, specially constructed
+                query <acronym>URL</acronym>s are used to describe what events should be returned.
+                The <classname>Zend_Gdata_Gbase_ItemQuery</classname> and
                 <classname>Zend_Gdata_Gbase_SnippetQuery</classname> classes simplify this task by
-                automatically constructing a query <acronym>URL</acronym> based on provided parameters.
+                automatically constructing a query <acronym>URL</acronym> based on provided
+                parameters.
             </para>
+
             <sect4 id="zend.gdata.gbase.retrieve.query.customeritems">
                 <title>Query Customer Items Feed</title>
+
                 <para>
-                    To execute a query against the customer items feed, invoke <methodname>newItemQuery()</methodname> and <methodname>getGbaseItemFeed()</methodname> methods:
+                    To execute a query against the customer items feed, invoke
+                    <methodname>newItemQuery()</methodname> and
+                    <methodname>getGbaseItemFeed()</methodname> methods:
                 </para>
+
                 <programlisting language="php"><![CDATA[
 $service = new Zend_Gdata_Gbase($client);
 $query = $service->newItemQuery();
@@ -217,15 +277,23 @@ $query->setSortOrder('descending');
 $query->setMaxResults('5');
 $feed = $service->getGbaseItemFeed($query);
 ]]></programlisting>
+
                 <para>
-                    A full list of these parameters is available at the <ulink url="http://code.google.com/apis/base/items-feed.html#QueParameters">Query parameters section</ulink> of the Customer Items Feed documentation.
+                    A full list of these parameters is available at the <ulink
+                        url="http://code.google.com/apis/base/items-feed.html#QueParameters">Query
+                        parameters section</ulink> of the Customer Items Feed documentation.
                 </para>
             </sect4>
+
             <sect4 id="zend.gdata.gbase.retrieve.query.snippets">
                 <title>Query Snippets Feed</title>
+
                 <para>
-                    To execute a query against the public snippets feed, invoke <methodname>newSnippetQuery()</methodname> and <methodname>getGbaseSnippetFeed()</methodname> methods:
+                    To execute a query against the public snippets feed, invoke
+                    <methodname>newSnippetQuery()</methodname> and
+                    <methodname>getGbaseSnippetFeed()</methodname> methods:
                 </para>
+
                 <programlisting language="php"><![CDATA[
 $service = new Zend_Gdata_Gbase();
 $query = $service->newSnippetQuery();
@@ -235,19 +303,28 @@ $query->setSortOrder('descending');
 $query->setMaxResults('5');
 $feed = $service->getGbaseSnippetFeed($query);
 ]]></programlisting>
+
                 <para>
-                    A full list of these parameters is available at the <ulink url="http://code.google.com/apis/base/snippets-feed.html#Parameters">Query parameters section</ulink> of the Snippets Feed documentation.
+                    A full list of these parameters is available at the <ulink
+                        url="http://code.google.com/apis/base/snippets-feed.html#Parameters">Query
+                        parameters section</ulink> of the Snippets Feed documentation.
                 </para>
             </sect4>
         </sect3>
+
         <sect3 id="zend.gdata.gbase.retrieve.iterate">
             <title>Iterate through the Items</title>
+
             <para>
-                Google Base items can contain item-specific attributes such as <code>&lt;g:main_ingredient&gt;</code> and <code>&lt;g:weight&gt;</code>.
+                Google Base items can contain item-specific attributes such as
+                <code>&lt;g:main_ingredient&gt;</code> and <code>&lt;g:weight&gt;</code>.
             </para>
+
             <para>
-                To iterate through all attributes of a given item, invoke <methodname>getGbaseAttributes()</methodname> and iterate through the results:
+                To iterate through all attributes of a given item, invoke
+                <methodname>getGbaseAttributes()</methodname> and iterate through the results:
             </para>
+
             <programlisting language="php"><![CDATA[
 foreach ($feed->entries as $entry) {
   // Get all attributes and print out the name and text value of each
@@ -258,9 +335,12 @@ foreach ($feed->entries as $entry) {
   }
 }
 ]]></programlisting>
+
             <para>
-                Or, you can look for specific attribute name and iterate through the results that match:
+                Or, you can look for specific attribute name and iterate through the results that
+                match:
             </para>
+
             <programlisting language="php"><![CDATA[
 foreach ($feed->entries as $entry) {
   // Print all main ingredients <g:main_ingredient>
@@ -272,19 +352,29 @@ foreach ($feed->entries as $entry) {
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.gbase.crud">
         <title>Insert, Update, and Delete Customer Items</title>
+
         <para>
-            A customer/owner can access his own Customer Items feed to insert, update, or delete their items. These operations do not apply to the public snippets feed.
+            A customer/owner can access his own Customer Items feed to insert, update, or delete
+            their items. These operations do not apply to the public snippets feed.
         </para>
+
         <para>
-            You can test a feed operation before it is actually executed by setting the dry-run flag (<varname>$dryRun</varname>) to <constant>TRUE</constant>. Once you are sure that you want to submit the data, set it to <constant>FALSE</constant> to execute the operation.
+            You can test a feed operation before it is actually executed by setting the dry-run flag
+            (<varname>$dryRun</varname>) to <constant>TRUE</constant>. Once you are sure that you
+            want to submit the data, set it to <constant>FALSE</constant> to execute the operation.
         </para>
+
         <sect3 id="zend.gdata.gbase.crud.insert">
             <title>Insert an Item</title>
+
             <para>
-                Items can be added by using the <methodname>insertGbaseItem()</methodname> method for the Base service:
+                Items can be added by using the <methodname>insertGbaseItem()</methodname> method
+                for the Base service:
             </para>
+
             <programlisting language="php"><![CDATA[
 $service = new Zend_Gdata_Gbase($client);
 $newEntry = $service->newItemEntry();
@@ -319,11 +409,14 @@ $dryRun = true;
 $createdEntry = $service->insertGbaseItem($newEntry, $dryRun);
 ]]></programlisting>
         </sect3>
+
         <sect3 id="zend.gdata.gbase.crud.modify">
             <title>Modify an Item</title>
+
             <para>
                 You can update each attribute element of an item as you iterate through them:
             </para>
+
             <programlisting language="php"><![CDATA[
 // Update the title
 $newTitle = "PHP Developer Handbook Second Edition";
@@ -367,22 +460,32 @@ $entry->save($dryRun);
 // $dryRun = true;
 // $service->updateGbaseItem($entry, $dryRun);
 ]]></programlisting>
+
             <para>
-                After making the changes, either invoke <methodname>save($dryRun)</methodname> method on the <classname>Zend_Gdata_Gbase_ItemEntry</classname> object or call <methodname>updateGbaseItem($entry, $dryRun)</methodname> method on the <classname>Zend_Gdata_Gbase</classname> object to save the changes.
+                After making the changes, either invoke <methodname>save($dryRun)</methodname>
+                method on the <classname>Zend_Gdata_Gbase_ItemEntry</classname> object or call
+                <methodname>updateGbaseItem($entry, $dryRun)</methodname> method on the
+                <classname>Zend_Gdata_Gbase</classname> object to save the changes.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.gbase.crud.delete">
             <title>Delete an Item</title>
+
             <para>
                 You can remove an item by calling <methodname>deleteGbaseItem()</methodname> method:
             </para>
+
             <programlisting language="php"><![CDATA[
 $dryRun = false;
 $service->deleteGbaseItem($entry, $dryRun);
 ]]></programlisting>
+
             <para>
-                Alternatively, you can invoke <methodname>delete()</methodname> on the <classname>Zend_Gdata_Gbase_ItemEntry</classname> object:
+                Alternatively, you can invoke <methodname>delete()</methodname> on the
+                <classname>Zend_Gdata_Gbase_ItemEntry</classname> object:
             </para>
+
             <programlisting language="php"><![CDATA[
 $dryRun = false;
 $entry->delete($dryRun);

+ 197 - 84
documentation/manual/en/module_specs/Zend_Gdata_Health.xml

@@ -2,27 +2,40 @@
 <!-- Reviewed: no -->
 <sect1 id="zend.gdata.health">
     <title>Using Google Health</title>
+
     <para>
-        The Google Health Data <acronym>API</acronym> is designed to enable developers to do two things:
+        The Google Health Data <acronym>API</acronym> is designed to enable developers to do two
+        things:
+
         <itemizedlist>
             <listitem>
                 <para>
-                    Read a user's Google Health profile or query for medical records that match particular criteria and then
-                    use the results to provide personalized functionality based on the data.
+                    Read a user's Google Health profile or query for medical records that match
+                    particular criteria and then use the results to provide personalized
+                    functionality based on the data.
                 </para>
-                </listitem>
+            </listitem>
+
             <listitem>
                 <para>
-                    Add new medical records to a user's profile by including CCR data when sending a notice to a user's profile. Note: The CCR data is stored as an <acronym>XML</acronym> blob
-                    within the &lt;atom&gt; entry. The library does not provide direct accessors to the object model but it does have helpers for extracting specific fields.
+                    Add new medical records to a user's profile by including CCR data when sending a
+                    notice to a user's profile. Note: The CCR data is stored as an
+                    <acronym>XML</acronym> blob within the &lt;atom&gt; entry. The library does not
+                    provide direct accessors to the object model but it does have helpers for
+                    extracting specific fields.
                 </para>
             </listitem>
         </itemizedlist>
     </para>
+
     <para>
-        There are three main feeds, each of which requires authentication. Unlike other Google Data <acronym>API</acronym>s, each Google Health feed has a limited set of
-        <acronym>HTTP</acronym> operations you can perform on it, depending on which authentication method you are using (ClientLogin or AuthSub/OAuth).
-        For a list of permitted operations, see <ulink url="http://code.google.com/apis/health/reference.html#Authentication">http://code.google.com/apis/health/reference.html#Authentication</ulink>.
+        There are three main feeds, each of which requires authentication. Unlike other Google Data
+        <acronym>API</acronym>s, each Google Health feed has a limited set of
+        <acronym>HTTP</acronym> operations you can perform on it, depending on which authentication
+        method you are using (ClientLogin or AuthSub/OAuth). For a list of permitted operations, see
+        <ulink
+            url="http://code.google.com/apis/health/reference.html#Authentication">http://code.google.com/apis/health/reference.html#Authentication</ulink>.
+
         <itemizedlist>
             <listitem>
                 <para>
@@ -30,92 +43,124 @@
                   use the profile feed to query a user's health profile for specific information.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                   <firstterm>Register Feed</firstterm>
                   use the register feed to reconcile new CCR data into a profile.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                  <firstterm>Profile List Feed</firstterm>
-                    the profile list feed should be used to determine which of the user's Health profiles to interact with.
-                    This feed is only available when using ClientLogin.
+                  <firstterm>Profile List Feed</firstterm> the profile list feed should be used to
+                  determine which of the user's Health profiles to interact with. This feed is only
+                  available when using ClientLogin.
                 </para>
             </listitem>
         </itemizedlist>
     </para>
+
     <para>
-        See <ulink url="http://code.google.com/apis/health/">http://code.google.com/apis/health</ulink>
+        See <ulink
+            url="http://code.google.com/apis/health/">http://code.google.com/apis/health</ulink>
         for more information about the Google Health <acronym>API</acronym>.
     </para>
+
     <sect2 id="zend.gdata.health.connect">
         <title>Connect To The Health Service</title>
+
         <para>
-            The Google Health <acronym>API</acronym>, like all Google Data <acronym>API</acronym>s, is based off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based format for managing web-based resources.
-            Traffic between a client and the Google Health servers occurs over <acronym>HTTP</acronym> and allows for authenticated connections.
+            The Google Health <acronym>API</acronym>, like all Google Data <acronym>API</acronym>s,
+            is based off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based
+            format for managing web-based resources. Traffic between a client and the Google Health
+            servers occurs over <acronym>HTTP</acronym> and allows for authenticated connections.
         </para>
+
         <para>
-            Before any transactions can occur, a connection needs to be made. Creating a connection to the Health servers involves two steps: creating an <acronym>HTTP</acronym> client
-            and binding a <classname>Zend_Gdata_Health</classname> service instance to that client.
+            Before any transactions can occur, a connection needs to be made. Creating a connection
+            to the Health servers involves two steps: creating an <acronym>HTTP</acronym> client and
+            binding a <classname>Zend_Gdata_Health</classname> service instance to that client.
         </para>
+
         <sect3 id="zend.gdata.health.connect.authentication">
             <title>Authentication</title>
+
             <para>
-                The Google Health <acronym>API</acronym> allows programmatic access to a user's Health profile. There are three authentication schemes that are supported by Google Health:
+                The Google Health <acronym>API</acronym> allows programmatic access to a user's
+                Health profile. There are three authentication schemes that are supported by Google
+                Health:
             </para>
+
             <itemizedlist>
                 <listitem>
                     <para>
-                        <firstterm>ClientLogin</firstterm>
-                        provides direct username/password authentication to the Health servers. Since this method requires that users provide your application
-                        with their password, this authentication scheme is only recommended for installed/desktop applications.
+                        <firstterm>ClientLogin</firstterm> provides direct username/password
+                        authentication to the Health servers. Since this method requires that users
+                        provide your application with their password, this authentication scheme is
+                        only recommended for installed/desktop applications.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <firstterm>AuthSub</firstterm>
-                        allows a user to authorize the sharing of their private data. This provides the same level of convenience as ClientLogin but without the
-                        security risk, making it an ideal choice for web-based applications. For Google Health, AuthSub must be used
-                        in registered and secure mode--meaning that all requests to the <acronym>API</acronym> must be digitally signed.
+                        <firstterm>AuthSub</firstterm> allows a user to authorize the sharing of
+                        their private data. This provides the same level of convenience as
+                        ClientLogin but without the security risk, making it an ideal choice for
+                        web-based applications. For Google Health, AuthSub must be used in
+                        registered and secure mode--meaning that all requests to the
+                        <acronym>API</acronym> must be digitally signed.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <firstterm>OAuth</firstterm>
-                        is an alternative to AuthSub. Although this authentication scheme is not discussed in this document, more information can
-                        be found in the <ulink url="http://code.google.com/apis/health/developers_guide_protocol.html#OAuth">Health Data <acronym>API</acronym> Developer's Guide</ulink>.
+                        <firstterm>OAuth</firstterm> is an alternative to AuthSub. Although this
+                        authentication scheme is not discussed in this document, more information
+                        can be found in the <ulink
+                            url="http://code.google.com/apis/health/developers_guide_protocol.html#OAuth">Health
+                            Data <acronym>API</acronym> Developer's Guide</ulink>.
                     </para>
                 </listitem>
             </itemizedlist>
+
             <para>
-                See
-                <ulink url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the Google Data <acronym>API</acronym> documentation</ulink> for more
+                See <ulink
+                    url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the
+                    Google Data <acronym>API</acronym> documentation</ulink> for more
                 information on each authentication method.
             </para>
         </sect3>
+
         <sect3 id="zend.gdata.health.connect.service">
             <title>Create A Health Service Instance</title>
+
             <para>
                 In order to interact with Google Health, the client library provides the
-                <classname>Zend_Gdata_Health</classname>
-                service class. This class provides a common interface to the Google Data and Atom Publishing Protocol models and assists in marshaling
-                requests to and from the Health <acronym>API</acronym>.
+                <classname>Zend_Gdata_Health</classname> service class. This class provides a common
+                interface to the Google Data and Atom Publishing Protocol models and assists in
+                marshaling requests to and from the Health <acronym>API</acronym>.
             </para>
+
             <para>
-                Once you've decided on an authentication scheme, the next step is to create an instance of
-                <classname>Zend_Gdata_Health</classname>
-                . This class should be passed an instance of
-                <classname>Zend_Gdata_HttpClient</classname>. This provides an interface for AuthSub/OAuth and ClientLogin to create a special
-                authenticated <acronym>HTTP</acronym> client.
+                Once you've decided on an authentication scheme, the next step is to create an
+                instance of <classname>Zend_Gdata_Health</classname>. This class should be passed an
+                instance of <classname>Zend_Gdata_HttpClient</classname>. This provides an interface
+                for AuthSub/OAuth and ClientLogin to create a special authenticated
+                <acronym>HTTP</acronym> client.
             </para>
+
             <para>
                 To test against the H9 Developer's (/h9) instead of Google Health (/health), the
-                <classname>Zend_Gdata_Health</classname> constructor takes an optional third argument for you to specify the H9 service name 'weaver'.
+                <classname>Zend_Gdata_Health</classname> constructor takes an optional third
+                argument for you to specify the H9 service name 'weaver'.
             </para>
+
             <para>
-                The example below shows how to create a Health service class using ClientLogin authentication:
+                The example below shows how to create a Health service class using ClientLogin
+                authentication:
             </para>
+
             <programlisting language="php"><![CDATA[
 // Parameters for ClientLogin authentication
 $healthServiceName = Zend_Gdata_Health::HEALTH_SERVICE_NAME;
@@ -131,11 +176,15 @@ $client = Zend_Gdata_ClientLogin::getHttpClient($user,
 // Create an instance of the Health service
 $service = new Zend_Gdata_Health($client);
 ]]></programlisting>
+
             <para>
-              A Health service using AuthSub can be created in a similar, though slightly more lengthy fashion. AuthSub is the
-              recommend interface to communicate with Google Health because each token is directly linked to a specific profile in
-              the user's account. Unlike other Google Data <acronym>API</acronym>s, it is required that all requests from your application be digitally signed.
+                A Health service using AuthSub can be created in a similar, though slightly more
+                lengthy fashion. AuthSub is the recommend interface to communicate with Google
+                Health because each token is directly linked to a specific profile in the user's
+                account. Unlike other Google Data <acronym>API</acronym>s, it is required that all
+                requests from your application be digitally signed.
             </para>
+
             <programlisting language="php"><![CDATA[
 /*
  * Retrieve the current URL so that the AuthSub server knows where to
@@ -221,31 +270,48 @@ $healthService = new Zend_Gdata_Health($client,
                                        'googleInc-MyTestAppName-v1.0',
                                        $userH9Sandbox);
 ]]></programlisting>
-            <para>NOTE: the remainder of this document will assume you are using AuthSub for authentication.</para>
+
+            <para>
+                NOTE: the remainder of this document will assume you are using AuthSub for
+                authentication.
+            </para>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.health.profilefeed">
         <title>Profile Feed</title>
+
         <para>
-            To query the user's profile feed, make sure your initial AuthSub token was requested with the <code>permission=1</code> parameter set.
-            The process of extracting data from the profile requires two steps, sending a query and iterating through the resulting feed.
+            To query the user's profile feed, make sure your initial AuthSub token was requested
+            with the <code>permission=1</code> parameter set. The process of extracting data from
+            the profile requires two steps, sending a query and iterating through the resulting
+            feed.
         </para>
+
         <sect3 id="zend.gdata.health.profilefeed.query">
             <title>Send a Structured Query</title>
+
             <para>
                 You can send structured queries to retrieve specific records from a user's profile.
             </para>
+
             <para>
-                When retrieving the profile using the Health <acronym>API</acronym>, specifically constructed query <acronym>URL</acronym>s are used to describe what (CCR) data
-                should be returned. The <classname>Zend_Gdata_Health_Query</classname> class helps simplify this task by automatically constructing a query
-                <acronym>URL</acronym> based on the parameters you set.
+                When retrieving the profile using the Health <acronym>API</acronym>, specifically
+                constructed query <acronym>URL</acronym>s are used to describe what (CCR) data
+                should be returned. The <classname>Zend_Gdata_Health_Query</classname> class helps
+                simplify this task by automatically constructing a query <acronym>URL</acronym>
+                based on the parameters you set.
             </para>
+
             <sect4 id="zend.gdata.health.profilefeed.query.construct">
                 <title>Query The Feed</title>
+
                 <para>
-                    To execute a query against the profile feed, invoke a new instance of an <classname>Zend_Gdata_Health_Query</classname> and
-                    call the service's <methodname>getHealthProfileFeed()</methodname> method:
+                    To execute a query against the profile feed, invoke a new instance of an
+                    <classname>Zend_Gdata_Health_Query</classname> and call the service's
+                    <methodname>getHealthProfileFeed()</methodname> method:
                 </para>
+
                 <programlisting language="php"><![CDATA[
 $healthService = new Zend_Gdata_Health($client);
 
@@ -259,26 +325,46 @@ $query->setCategory("medication");
 
 $profileFeed = $healthService->getHealthProfileFeed($query);
 ]]></programlisting>
-                <para>Using <methodname>setDigest("true")</methodname> returns all of user's CCR data in a single Atom <code>&lt;entry&gt;</code>.</para>
-                <para>The <methodname>setCategory()</methodname> helper can be passed an additional parameter to return more specific CCR
-                information. For example, to return just the medication Lipitor, use <methodname>setCategory("medication", "Lipitor")</methodname>. The same
-                methodology can be applied to other categories such as conditions, allergies, lab results, etc.</para>
+
                 <para>
-                    A full list of supported query parameters is available in the <ulink url="http://code.google.com/apis/health/reference.html#Parameters">query parameters section</ulink>
-                    of the Health <acronym>API</acronym> Reference Guide.
+                    Using <methodname>setDigest("true")</methodname> returns all of user's CCR data
+                    in a single Atom <code>&lt;entry&gt;</code>.
+                </para>
+
+                <para>
+                    The <methodname>setCategory()</methodname> helper can be passed an additional
+                    parameter to return more specific CCR information. For example, to return just
+                    the medication Lipitor, use
+                    <methodname>setCategory("medication", "Lipitor")</methodname>. The same
+                    methodology can be applied to other categories such as conditions, allergies,
+                    lab results, etc.
+                </para>
+
+                <para>
+                    A full list of supported query parameters is available in the <ulink
+                        url="http://code.google.com/apis/health/reference.html#Parameters">query
+                        parameters section</ulink> of the Health <acronym>API</acronym> Reference
+                    Guide.
                 </para>
             </sect4>
         </sect3>
+
         <sect3 id="zend.gdata.health.profilefeed.iterate">
             <title>Iterate Through The Profile Entries</title>
+
             <para>
-                Each Google Health entry contains CCR data, however, using the <code>digest=true</code> query parameter will
-                consolidate all of the CCR elements (that match your query) into a single Atom <code>&lt;entry&gt;</code>.
+                Each Google Health entry contains CCR data, however, using the
+                <code>digest=true</code> query parameter will consolidate all of the CCR elements
+                (that match your query) into a single Atom <code>&lt;entry&gt;</code>.
             </para>
+
             <para>
-                To retrieve the full CCR information from an entry, make a call to the <classname>Zend_Gdata_Health_ProfileEntry</classname> class's <methodname>getCcr()</methodname> method.
-                That returns a <classname>Zend_Gdata_Health_Extension_CCR</classname>:
+                To retrieve the full CCR information from an entry, make a call to the
+                <classname>Zend_Gdata_Health_ProfileEntry</classname> class's
+                <methodname>getCcr()</methodname> method. That returns a
+                <classname>Zend_Gdata_Health_Extension_CCR</classname>:
             </para>
+
             <programlisting language="php"><![CDATA[
 $entries = $profileFeed->getEntries();
 foreach ($entries as $entry) {
@@ -293,15 +379,22 @@ foreach ($entries as $entry) {
     }
 }
 ]]></programlisting>
+
             <para>
-              Here, the <methodname>getCcr()</methodname> method is used in conjunction with a magic helper to drill down and extract just the
-              medication data from the entry's CCR. The formentioned magic helper takes the form <methodname>getCATEGORYNAME()</methodname>, where
-              <constant>CATEGORYNAME</constant> is a supported Google Health category. See the
-              <ulink url="http://code.google.com/apis/health/reference.html#CatQueries">Google Health reference Guide</ulink> for the possible categories.
+                Here, the <methodname>getCcr()</methodname> method is used in conjunction with a
+                magic helper to drill down and extract just the medication data from the entry's
+                CCR. The formentioned magic helper takes the form
+                <methodname>getCATEGORYNAME()</methodname>, where <constant>CATEGORYNAME</constant>
+                is a supported Google Health category. See the <ulink
+                    url="http://code.google.com/apis/health/reference.html#CatQueries">Google Health
+                    reference Guide</ulink> for the possible categories.
             </para>
+
             <para>
-               To be more efficient, you can also use category queries to only return the necessary CCR from the Google Health servers. Then, iterate through those results:
+                To be more efficient, you can also use category queries to only return the necessary
+                CCR from the Google Health servers. Then, iterate through those results:
             </para>
+
             <programlisting language="php"><![CDATA[
 $query = new Zend_Gdata_Health_Query();
 $query->setDigest("true");
@@ -320,20 +413,28 @@ foreach ($conditions as $cond) {
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.health.profilelist">
         <title>Profile List Feed</title>
+
         <para>NOTE: This feed is only available when using ClientLogin</para>
+
         <para>
-            Since ClientLogin requires a profile ID with each of its feeds, applications will likely want to query this feed first in order
-            to select the appropriate profile. The profile list feed returns Atom entries corresponding each profile in the user's
-            Google Health account. The profile ID is returned in the Atom <code>&lt;content&gt;</code> and the profile name in the
-            <code>&lt;title&gt;</code> element.
+            Since ClientLogin requires a profile ID with each of its feeds, applications will likely
+            want to query this feed first in order to select the appropriate profile. The profile
+            list feed returns Atom entries corresponding each profile in the user's Google Health
+            account. The profile ID is returned in the Atom <code>&lt;content&gt;</code> and the
+            profile name in the <code>&lt;title&gt;</code> element.
         </para>
+
         <sect3 id="zend.gdata.health.profilelist.query">
             <title>Query The Feed</title>
+
             <para>
-                To execute a query against the profile list feed, call the service's <methodname>getHealthProfileListFeed()</methodname> method:
+                To execute a query against the profile list feed, call the service's
+                <methodname>getHealthProfileListFeed()</methodname> method:
             </para>
+
             <programlisting language="php"><![CDATA[
 $client = Zend_Gdata_ClientLogin::getHttpClient('user@gmail.com',
                                                 'pa$$word',
@@ -348,10 +449,14 @@ foreach ($entries as $entry) {
     echo 'profile ID: ' . $entry->getProfileID() . '</p>';
 }
 ]]></programlisting>
+
             <para>
-              Once you've determined which profile to use, call <methodname>setProfileID()</methodname> with the profileID as an argument.
-              This will restrict subsequent <acronym>API</acronym> requests to be against that particular profile:
+                Once you've determined which profile to use, call
+                <methodname>setProfileID()</methodname> with the profileID as an argument. This will
+                restrict subsequent <acronym>API</acronym> requests to be against that particular
+                profile:
             </para>
+
             <programlisting language="php"><![CDATA[
 // use the first profile
 $profileID = $feed->entry[0]->getProfileID();
@@ -364,20 +469,28 @@ echo '<p><b>Queried profileID</b>: ' . $profileID . '</p>';
 ]]></programlisting>
         </sect3>
     </sect2>
+
     <sect2 id="zend.gdata.health.notice">
         <title>Sending Notices to the Register Feed</title>
+
         <para>
-            Individual posts to the register feed are known as notices. Notice are sent from third-party applications to inform the user
-            of a new event. With AuthSub/OAuth, notices are the single means by which your application can add new CCR information
-            into a user's profile. Notices can contain plain text (including certain <acronym>XHTML</acronym> elements), a CCR document, or both. As an example,
-            notices might be sent to remind users to pick up a prescription, or they might contain lab results in the CCR format.
+            Individual posts to the register feed are known as notices. Notice are sent from
+            third-party applications to inform the user of a new event. With AuthSub/OAuth, notices
+            are the single means by which your application can add new CCR information into a user's
+            profile. Notices can contain plain text (including certain <acronym>XHTML</acronym>
+            elements), a CCR document, or both. As an example, notices might be sent to remind users
+            to pick up a prescription, or they might contain lab results in the CCR format.
         </para>
-            <sect3 id="zend.gdata.health.notice.send">
-                <title>Sending a notice</title>
-          <para>
-              Notices can be sent by using the <methodname>sendHealthNotice()</methodname> method for the Health service:
-          </para>
-          <programlisting language="php"><![CDATA[
+
+        <sect3 id="zend.gdata.health.notice.send">
+            <title>Sending a notice</title>
+
+            <para>
+                Notices can be sent by using the <methodname>sendHealthNotice()</methodname> method
+                for the Health service:
+            </para>
+
+            <programlisting language="php"><![CDATA[
 $healthService = new Zend_Gdata_Health($client);
 
 $subject = "Title of your notice goes here";
@@ -409,6 +522,6 @@ $responseEntry = $healthService->sendHealthNotice($subject,
                                                   "html",
                                                   $ccr);
 ]]></programlisting>
-      </sect3>
+        </sect3>
     </sect2>
 </sect1>

+ 183 - 96
documentation/manual/en/module_specs/Zend_Gdata_Photos.xml

@@ -25,6 +25,7 @@
 
     <note>
         <title>Authentication</title>
+
         <para>
             The <acronym>API</acronym> provides authentication via AuthSub (recommended)
             and ClientAuth. <acronym>HTTP</acronym> connections must be authenticated for write
@@ -34,26 +35,30 @@
 
     <sect2 id="zend.gdata.photos.connecting">
         <title>Connecting To The Service</title>
+
         <para>
-            The Picasa Web Albums <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is based off of the Atom Publishing Protocol (APP),
-            an <acronym>XML</acronym> based format for managing web-based resources. Traffic between a client and the
-            servers occurs over <acronym>HTTP</acronym> and allows for both authenticated and unauthenticated connections.
+            The Picasa Web Albums <acronym>API</acronym>, like all GData <acronym>API</acronym>s, is
+            based off of the Atom Publishing Protocol (APP), an <acronym>XML</acronym> based format
+            for managing web-based resources. Traffic between a client and the servers occurs over
+            <acronym>HTTP</acronym> and allows for both authenticated and unauthenticated connections.
         </para>
 
         <para>
-            Before any transactions can occur, this connection needs to be made. Creating a connection to the
-            Picasa servers involves two steps: creating an <acronym>HTTP</acronym> client and binding a
-            <classname>Zend_Gdata_Photos</classname>
+            Before any transactions can occur, this connection needs to be made. Creating a
+            connection to the Picasa servers involves two steps: creating an <acronym>HTTP</acronym>
+            client and binding a <classname>Zend_Gdata_Photos</classname>
             service instance to that client.
         </para>
 
         <sect3 id="zend.gdata.photos.connecting.authentication">
             <title>Authentication</title>
+
             <para>
-                The Google Picasa <acronym>API</acronym> allows access to both public and private photo feeds. Public feeds
-                do not require authentication, but are read-only and offer reduced functionality. Private feeds
-                offers the most complete functionality but requires an authenticated connection to the Picasa
-                servers. There are three authentication schemes that are supported by Google Picasa :
+                The Google Picasa <acronym>API</acronym> allows access to both public and private
+                photo feeds. Public feeds do not require authentication, but are read-only and offer
+                reduced functionality. Private feeds offers the most complete functionality but
+                requires an authenticated connection to the Picasa servers. There are three
+                authentication schemes that are supported by Google Picasa :
             </para>
 
             <itemizedlist>
@@ -67,6 +72,7 @@
                         authentication schemes are insufficient.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <firstterm>AuthSub</firstterm>
@@ -88,30 +94,37 @@
                 appropriate authenticated connection. For more information,
                 please see section the
                 <link linkend="zend.gdata.introduction.authentication">Authentication section</link>
-                of this manual or the
-                <ulink url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the Google Data <acronym>API</acronym> Developer's Guide</ulink>.
+                of this manual or the <ulink
+                    url="http://code.google.com/apis/gdata/auth.html">Authentication Overview in the
+                    Google Data <acronym>API</acronym> Developer's Guide</ulink>.
             </para>
         </sect3>
 
         <sect3 id="zend.gdata.photos.connecting.service">
             <title>Creating A Service Instance</title>
+
             <para>
                 In order to interact with the servers, this library provides the
-                <classname>Zend_Gdata_Photos</classname> service class. This class provides a common interface to the
-                Google Data and Atom Publishing Protocol models and assists in marshaling requests to and from
-                the servers.
+                <classname>Zend_Gdata_Photos</classname> service class. This class provides a common
+                interface to the Google Data and Atom Publishing Protocol models and assists in
+                marshaling requests to and from the servers.
             </para>
 
             <para>
                 Once deciding on an authentication scheme, the next step is to create an instance of
                 <classname>Zend_Gdata_Photos</classname>. The class constructor takes an instance of
-                <classname>Zend_Http_Client</classname> as a single argument. This provides an interface for AuthSub
-                and ClientAuth authentication, as both of these require creation of a special authenticated
-                <acronym>HTTP</acronym> client. If no arguments are provided, an unauthenticated instance of
-                <classname>Zend_Http_Client</classname> will be automatically created.
+                <classname>Zend_Http_Client</classname> as a single argument. This provides an
+                interface for AuthSub and ClientAuth authentication, as both of these require
+                creation of a special authenticated <acronym>HTTP</acronym> client. If no arguments
+                are provided, an unauthenticated instance of <classname>Zend_Http_Client</classname>
+                will be automatically created.
+            </para>
+
+            <para>
+                The example below shows how to create a service class using ClientAuth
+                authentication:
             </para>
 
-            <para>The example below shows how to create a service class using ClientAuth authentication:</para>
             <programlisting language="php"><![CDATA[
 // Parameters for ClientAuth authentication
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
@@ -125,7 +138,11 @@ $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
 $service = new Zend_Gdata_Photos($client);
 ]]></programlisting>
 
-            <para>A service instance using AuthSub can be created in a similar, though slightly more lengthy fashion:</para>
+            <para>
+                A service instance using AuthSub can be created in a similar, though slightly more
+                lengthy fashion:
+            </para>
+
             <programlisting language="php"><![CDATA[
 session_start();
 
@@ -214,7 +231,10 @@ function getAuthSubHttpClient()
 $service = new Zend_Gdata_Photos(getAuthSubHttpClient());
 ]]></programlisting>
 
-            <para>Finally, an unauthenticated server can be created for use with public feeds:</para>
+            <para>
+                Finally, an unauthenticated server can be created for use with public feeds:
+            </para>
+
             <programlisting language="php"><![CDATA[
 // Create an instance of the service using an unauthenticated HTTP client
 $service = new Zend_Gdata_Photos();
@@ -224,36 +244,39 @@ $service = new Zend_Gdata_Photos();
 
     <sect2 id="zend.gdata.photos.queries">
         <title>Understanding and Constructing Queries</title>
+
         <para>
-            The primary method to request data from the service is by constructing a query. There are query
-            classes for each of the following types:
+            The primary method to request data from the service is by constructing a query. There
+            are query classes for each of the following types:
         </para>
 
         <itemizedlist>
             <listitem>
                 <para>
-                    <firstterm>User</firstterm>
-                    is used to specify the user whose data is being searched for, and is specified as a username.
-                    If no user is provided, "default" will be used instead to indicate the currently authenticated
-                    user (if authenticated).
+                    <firstterm>User</firstterm> is used to specify the user whose data is being
+                    searched for, and is specified as a username. if no user is provided, "default"
+                    will be used instead to indicate the currently authenticated user (if
+                    authenticated).
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Album</firstterm>
-                    is used to specify the album which is being searched for, and is specified as either an id,
-                    or an album name.
+                    <firstterm>Album</firstterm> is used to specify the album which is being
+                    searched for, and is specified as either an id, or an album name.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Photo</firstterm>
-                    is used to specify the photo which is being searched for, and is specified as an id.
+                    <firstterm>Photo</firstterm> is used to specify the photo which is being
+                    searched for, and is specified as an id.
                 </para>
             </listitem>
         </itemizedlist>
 
         <para>A new <code>UserQuery</code> can be constructed as followed:</para>
+
         <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -264,86 +287,91 @@ $query->setUser("sample.user");
 ]]></programlisting>
 
         <para>
-            For each query, a number of parameters limiting the search can be requested, or specified,
-            with get(Parameter) and set(Parameter), respectively. They are as follows:
+            for each query, a number of parameters limiting the search can be requested, or
+            specified, with get(Parameter) and set(Parameter), respectively. They are as follows:
         </para>
 
         <itemizedlist>
             <listitem>
                 <para>
-                    <firstterm>Projection</firstterm>
-                    sets the format of the data returned in the feed, as either "api" or "base". Normally,
-                    "api" is desired. The default is "api".
+                    <firstterm>Projection</firstterm> sets the format of the data returned in the
+                    feed, as either "api" or "base". Normally, "api" is desired. The default is
+                    "api".
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Type</firstterm>
-                    sets the type of element to be returned, as either "feed" or "entry". The default is "feed".
+                    <firstterm>Type</firstterm> sets the type of element to be returned, as either
+                    "feed" or "entry". The default is "feed".
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Access</firstterm>
-                    sets the visibility of items to be returned, as "all", "public", or "private". The default is
-                    "all". Non-public elements will only be returned if the query is searching for the
-                    authenticated user.
+                    <firstterm>Access</firstterm> sets the visibility of items to be returned, as
+                    "all", "public", or "private". The default is "all". Non-public elements will
+                    only be returned if the query is searching for the authenticated user.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Tag</firstterm>
-                    sets a tag filter for returned items. When a tag is set, only items tagged with this value
-                    will return.
+                    <firstterm>Tag</firstterm> sets a tag filter for returned items. When a tag is
+                    set, only items tagged with this value will return.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Kind</firstterm>
-                    sets the kind of elements to return. When kind is specified, only entries that match this
-                    value will be returned.
+                    <firstterm>Kind</firstterm> sets the kind of elements to return. When kind is
+                    specified, only entries that match this value will be returned.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>ImgMax</firstterm>
-                    sets the maximum image size for entries returned. Only image entries smaller than this value
-                    will be returned.
+                    <firstterm>ImgMax</firstterm> sets the maximum image size for entries returned.
+                    Only image entries smaller than this value will be returned.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>Thumbsize</firstterm>
-                    sets the thumbsize of entries that are returned. Any retrieved entry will have a thumbsize
-                    equal to this value.
+                    <firstterm>Thumbsize</firstterm> sets the thumbsize of entries that are
+                    returned. Any retrieved entry will have a thumbsize equal to this value.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>User</firstterm>
-                    sets the user whose data is being searched for. The default is "default".
+                    <firstterm>User</firstterm> sets the user whose data is being searched for. The
+                    default is "default".
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>AlbumId</firstterm>
-                    sets the id of the album being searched for. This element only applies to album and photo queries.
-                    In the case of photo queries, this specifies the album that contains the requested photo. The
-                    album id is mutually exclusive with the album's name. Setting one unsets the other.
+                    <firstterm>AlbumId</firstterm> sets the id of the album being searched for. This
+                    element only applies to album and photo queries. In the case of photo queries,
+                    this specifies the album that contains the requested photo. The album id is
+                    mutually exclusive with the album's name. Setting one unsets the other.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>AlbumName</firstterm>
-                    sets the name of the album being searched for. This element only applies to the album and photo
-                    queries. In the case of photo queries, this specifies the album that contains the requested photo.
-                    The album name is mutually exclusive with the album's id. Setting one unsets the other.
+                    <firstterm>AlbumName</firstterm> sets the name of the album being searched for.
+                    This element only applies to the album and photo queries. In the case of photo
+                    queries, this specifies the album that contains the requested photo. The album
+                    name is mutually exclusive with the album's id. Setting one unsets the other.
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <firstterm>PhotoId</firstterm>
-                    sets the id of the photo being searched for. This element only applies to photo queries.
+                    <firstterm>PhotoId</firstterm> sets the id of the photo being searched for. This
+                    element only applies to photo queries.
                 </para>
             </listitem>
         </itemizedlist>
@@ -351,6 +379,7 @@ $query->setUser("sample.user");
 
     <sect2 id="zend.gdata.photos.retrieval">
         <title>Retrieving Feeds And Entries</title>
+
         <para>
             The service has functions to retrieve a feed, or individual entries, for users, albums,
             and individual photos.
@@ -358,12 +387,18 @@ $query->setUser("sample.user");
 
         <sect3 id="zend.gdata.photos.user_retrieval">
             <title>Retrieving A User</title>
+
+            <para>
+                The service supports retrieving a user feed and list of the user's content. If the
+                requested user is also the authenticated user, entries marked as
+                "<code>hidden</code>" will also be returned.
+            </para>
+
             <para>
-                The service supports retrieving a user feed and list of the user's content. If the requested
-                user is also the authenticated user, entries marked as "<code>hidden</code>" will also be returned.
+                The user feed can be accessed by passing the username to the
+                <code>getUserFeed</code> method:
             </para>
 
-            <para>The user feed can be accessed by passing the username to the <code>getUserFeed</code> method:</para>
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -377,6 +412,7 @@ try {
 ]]></programlisting>
 
             <para>Or, the feed can be accessed by constructing a query, first:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -392,7 +428,10 @@ try {
 }
 ]]></programlisting>
 
-            <para>Constructing a query also provides the ability to request a user entry object:</para>
+            <para>
+                Constructing a query also provides the ability to request a user entry object:
+            </para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -412,11 +451,16 @@ try {
 
         <sect3 id="zend.gdata.photos.album_retrieval">
             <title>Retrieving An Album</title>
-            <para>The service supports retrieving an album feed and a list of the album's content.</para>
 
             <para>
-                The album feed is accessed by constructing a query object and passing it to <code>getAlbumFeed</code>:
+                The service supports retrieving an album feed and a list of the album's content.
             </para>
+
+            <para>
+                The album feed is accessed by constructing a query object and passing it to
+                <code>getAlbumFeed</code>:
+            </para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -434,11 +478,15 @@ try {
 ]]></programlisting>
 
             <para>
-                Alternatively, the query object can be given an album name with <code>setAlbumName</code>. Setting
-                the album name is mutually exclusive with setting the album id, and setting one will unset the other.
+                Alternatively, the query object can be given an album name with
+                <code>setAlbumName</code>. Setting the album name is mutually exclusive with setting
+                the album id, and setting one will unset the other.
+            </para>
+
+            <para>
+                Constructing a query also provides the ability to request an album entry object:
             </para>
 
-            <para>Constructing a query also provides the ability to request an album entry object:</para>
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -459,11 +507,17 @@ try {
 
         <sect3 id="zend.gdata.photos.photo_retrieval">
             <title>Retrieving A Photo</title>
-            <para>The service supports retrieving a photo feed and a list of associated comments and tags.</para>
 
             <para>
-                The photo feed is accessed by constructing a query object and passing it to <code>getPhotoFeed</code>:
+                The service supports retrieving a photo feed and a list of associated comments and
+                tags.
+            </para>
+
+            <para>
+                The photo feed is accessed by constructing a query object and passing it to
+                <code>getPhotoFeed</code>:
             </para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -481,7 +535,10 @@ try {
 }
 ]]></programlisting>
 
-            <para>Constructing a query also provides the ability to request a photo entry object:</para>
+            <para>
+                Constructing a query also provides the ability to request a photo entry object:
+            </para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -503,13 +560,18 @@ try {
 
         <sect3 id="zend.gdata.photos.comment_retrieval">
             <title>Retrieving A Comment</title>
+
             <para>
-                The service supports retrieving comments from a feed of a different type. By setting a query
-                to return a kind of "comment", a feed request can return comments associated with a specific user,
-                album, or photo.
+                The service supports retrieving comments from a feed of a different type. By setting
+                a query to return a kind of "comment", a feed request can return comments associated
+                with a specific user, album, or photo.
+            </para>
+
+            <para>
+                Performing an action on each of the comments on a given photo can be accomplished
+                as follows:
             </para>
 
-            <para>Performing an action on each of the comments on a given photo can be accomplished as follows:</para>
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -537,12 +599,18 @@ try {
 
         <sect3 id="zend.gdata.photos.tag_retrieval">
             <title>Retrieving A Tag</title>
+
+            <para>
+                The service supports retrieving tags from a feed of a different type. By setting a
+                query to return a kind of "tag", a feed request can return tags associated with a
+                specific photo.
+            </para>
+
             <para>
-                The service supports retrieving tags from a feed of a different type. By setting a query
-                to return a kind of "tag", a feed request can return tags associated with a specific photo.
+                Performing an action on each of the tags on a given photo can be accomplished as
+                follows:
             </para>
 
-            <para>Performing an action on each of the tags on a given photo can be accomplished as follows:</para>
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -567,16 +635,18 @@ try {
 }
 ]]></programlisting>
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.photos.creation">
         <title>Creating Entries</title>
+
         <para>The service has functions to create albums, photos, comments, and tags.</para>
 
         <sect3 id="zend.gdata.photos.album_creation">
             <title>Creating An Album</title>
+
             <para>The service supports creating a new album for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -591,7 +661,9 @@ $service->insertAlbumEntry($entry);
 
         <sect3 id="zend.gdata.photos.photo_creation">
             <title>Creating A Photo</title>
+
             <para>The service supports creating a new photo for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -618,7 +690,9 @@ $service->insertPhotoEntry($entry, $albumEntry);
 
         <sect3 id="zend.gdata.photos.comment_creation">
             <title>Creating A Comment</title>
+
             <para>The service supports creating a new comment for a photo:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -642,7 +716,9 @@ $service->insertCommentEntry($entry, $photoEntry);
 
         <sect3 id="zend.gdata.photos.tag_creation">
             <title>Creating A Tag</title>
+
             <para>The service supports creating a new tag for a photo:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -662,16 +738,18 @@ $photoEntry = $service->getPhotoEntry($photoQuery);
 $service->insertTagEntry($entry, $photoEntry);
 ]]></programlisting>
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.photos.deletion">
         <title>Deleting Entries</title>
+
         <para>The service has functions to delete albums, photos, comments, and tags.</para>
 
         <sect3 id="zend.gdata.photos.album_deletion">
             <title>Deleting An Album</title>
+
             <para>The service supports deleting an album for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -690,7 +768,9 @@ $service->deleteAlbumEntry($entry, true);
 
         <sect3 id="zend.gdata.photos.photo_deletion">
             <title>Deleting A Photo</title>
+
             <para>The service supports deleting a photo for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -710,7 +790,9 @@ $service->deletePhotoEntry($entry, true);
 
         <sect3 id="zend.gdata.photos.comment_deletion">
             <title>Deleting A Comment</title>
+
             <para>The service supports deleting a comment for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -732,7 +814,9 @@ $service->deleteCommentEntry($entry, true);
 
         <sect3 id="zend.gdata.photos.tag_deletion">
             <title>Deleting A Tag</title>
+
             <para>The service supports deleting a tag for an authenticated user:</para>
+
             <programlisting language="php"><![CDATA[
 $service = Zend_Gdata_Photos::AUTH_SERVICE_NAME;
 $client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
@@ -761,17 +845,21 @@ $service->deleteTagEntry($tagEntry, true);
 
         <sect3 id="zend.gdata.photos.optimistic_concurrenty">
             <title>Optimistic Concurrency (Notes On Deletion)</title>
+
             <para>
-                GData feeds, including those of the Picasa Web Albums service, implement optimistic concurrency,
-                a versioning system that prevents users from overwriting changes, inadvertently. When
-                deleting a entry through the service class, if the entry has been modified since it was
-                last fetched, an exception will be thrown, unless explicitly set otherwise (in which case
-                the deletion is retried on the updated entry).
+                GData feeds, including those of the Picasa Web Albums service, implement optimistic
+                concurrency, a versioning system that prevents users from overwriting changes,
+                inadvertently. When deleting a entry through the service class, if the entry has
+                been modified since it was last fetched, an exception will be thrown, unless
+                explicitly set otherwise (in which case the deletion is retried on the updated
+                entry).
             </para>
 
             <para>
-                An example of how to handle versioning during a deletion is shown by <code>deleteAlbumEntry</code>:
+                An example of how to handle versioning during a deletion is shown by
+                <code>deleteAlbumEntry</code>:
             </para>
+
             <programlisting language="php"><![CDATA[
 // $album is the albumEntry to be deleted
 try {
@@ -787,6 +875,5 @@ try {
 }
 ]]></programlisting>
         </sect3>
-
     </sect2>
 </sect1>

+ 17 - 15
documentation/manual/en/module_specs/Zend_Gdata_Spreadsheets.xml

@@ -12,13 +12,14 @@
     </para>
 
     <para>
-        See
-        <ulink url="http://code.google.com/apis/spreadsheets/overview.html">http://code.google.com/apis/spreadsheets/overview.html</ulink>
+        See <ulink
+            url="http://code.google.com/apis/spreadsheets/overview.html">http://code.google.com/apis/spreadsheets/overview.html</ulink>
         for more information about the Google Spreadsheets <acronym>API</acronym>.
     </para>
 
     <sect2 id="zend.gdata.spreadsheets.creating">
         <title>Create a Spreadsheet</title>
+
         <para>
             The Spreadsheets data <acronym>API</acronym> does not currently provide a way to
             programmatically create or delete a spreadsheet.
@@ -27,6 +28,7 @@
 
     <sect2 id="zend.gdata.spreadsheets.listspreadsheets">
         <title>Get a List of Spreadsheets</title>
+
         <para>
             You can get a list of spreadsheets for a particular user by using
             the <code>getSpreadsheetFeed</code> method of the Spreadsheets
@@ -46,6 +48,7 @@ $feed = $spreadsheetService->getSpreadsheetFeed();
 
      <sect2 id="zend.gdata.spreadsheets.listworksheets">
         <title>Get a List of Worksheets</title>
+
         <para>
             A given spreadsheet may contain multiple worksheets. For each
             spreadsheet, there's a worksheets metafeed listing all the
@@ -73,18 +76,19 @@ $feed = $spreadsheetService->getWorksheetFeed($query);
             objects (<code>$feed->entries</code>), each of which represents a
             single worksheet.
         </para>
-
     </sect2>
 
     <sect2 id="zend.gdata.spreadsheets.listfeeds">
         <title>Interacting With List-based Feeds</title>
+
         <para>
             A given worksheet generally contains multiple rows, each
             containing multiple cells. You can request data from the
             worksheet either as a list-based feed, in which each entry
             represents a row, or as a cell-based feed, in which each
-            entry represents a single cell. For information on cell-based
-            feeds, see <link linkend="zend.gdata.spreadsheets.cellfeeds">Interacting with cell-based feeds</link>.
+            entry represents a single cell. For information on cell-based feeds, see <link
+                linkend="zend.gdata.spreadsheets.cellfeeds">Interacting with cell-based
+                feeds</link>.
         </para>
 
         <para>
@@ -121,6 +125,7 @@ $feed = $spreadsheetService->getWorksheetFeed($query);
 
         <sect3 id="zend.gdata.spreadsheets.listfeeds.get">
             <title>Get a List-based Feed</title>
+
             <para>
                 To retrieve a worksheet's list feed, use the
                 <code>getListFeed</code> method of the Spreadsheets service.
@@ -143,9 +148,9 @@ $listFeed = $spreadsheetService->getListFeed($query);
             </para>
 
             <para>
-              Each <classname>Zend_Gdata_Spreadsheets_ListEntry</classname> contains an
-              array, <code>custom</code>, which contains the data for that
-              row. You can extract and display this array:
+                Each <classname>Zend_Gdata_Spreadsheets_ListEntry</classname> contains an
+                array, <code>custom</code>, which contains the data for that
+                row. You can extract and display this array:
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -156,9 +161,9 @@ foreach($rowData as $customEntry) {
 ]]></programlisting>
 
             <para>
-              An alternate version of this array, <code>customByName</code>,
-              allows direct access to an entry's cells by name. This is
-              convenient when trying to access a specific header:
+                An alternate version of this array, <code>customByName</code>,
+                allows direct access to an entry's cells by name. This is
+                convenient when trying to access a specific header:
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -291,7 +296,6 @@ $spreadsheetService->deleteRow($listEntry);
 $listEntry->delete();
 ]]></programlisting>
         </sect3>
-
     </sect2>
 
     <sect2 id="zend.gdata.spreadsheets.cellfeeds">
@@ -308,6 +312,7 @@ $listEntry->delete();
 
         <sect3 id="zend.gdata.spreadsheets.cellfeeds.get">
             <title>Get a Cell-based Feed</title>
+
             <para>
                 To retrieve a worksheet's cell feed, use the
                 <code>getCellFeed</code> method of the Spreadsheets service.
@@ -337,7 +342,6 @@ foreach($cellFeed as $cellEntry) {
   echo "$row, $col = $val\n";
 }
 ]]></programlisting>
-
         </sect3>
 
         <sect3 id="zend.gdata.spreadsheets.cellfeeds.cellrangequery">
@@ -386,7 +390,5 @@ $updatedCell = $spreadsheetService->updateCell($row,
                 the data in a cell, even if the cell is empty.
             </para>
         </sect3>
-
     </sect2>
-
 </sect1>

+ 284 - 215
documentation/manual/en/module_specs/Zend_Gdata_YouTube.xml

@@ -11,48 +11,62 @@
     </para>
 
     <para>
-      For more information on the YouTube Data <acronym>API</acronym>, please refer
-      to the official <ulink url="http://code.google.com/apis/youtube/developers_guide_php.html">
-        <acronym>PHP</acronym> Developer's Guide</ulink> on code.google.com.
+        For more information on the YouTube Data <acronym>API</acronym>, please refer
+        to the official <ulink
+            url="http://code.google.com/apis/youtube/developers_guide_php.html"><acronym>PHP</acronym>
+            Developer's Guide</ulink> on code.google.com.
     </para>
 
     <sect2 id="zend.gdata.youtube.authentication">
         <title>Authentication</title>
+
         <para>
-          The YouTube Data <acronym>API</acronym> allows read-only access to public data, which
-          does not require authentication. For any write requests, a user
-          needs to authenticate either using ClientLogin or AuthSub authentication. Please refer to the <ulink url="http://code.google.com/apis/youtube/developers_guide_php.html#Authentication">Authentication section in the <acronym>PHP</acronym> Developer's Guide</ulink> for more detail.
+            The YouTube Data <acronym>API</acronym> allows read-only access to public data, which
+            does not require authentication. For any write requests, a user
+            needs to authenticate either using ClientLogin or AuthSub authentication. Please refer
+            to the <ulink
+                url="http://code.google.com/apis/youtube/developers_guide_php.html#Authentication">Authentication
+                section in the <acronym>PHP</acronym> Developer's Guide</ulink> for more detail.
         </para>
     </sect2>
 
     <sect2 id="zend.gdata.youtube.developer_key">
         <title>Developer Keys and Client ID</title>
+
         <para>
             A developer key identifies the YouTube developer that is submitting
             an <acronym>API</acronym> request. A client ID identifies your application for logging
-            and debugging purposes. Please visit <ulink url="http://code.google.com/apis/youtube/dashboard/">http://code.google.com/apis/youtube/dashboard/</ulink> to obtain a developer key and client ID. The example below demonstrates how to pass the developer key and client ID to the <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube.html">Zend_Gdata_YouTube</ulink> service object.
+            and debugging purposes. Please visit <ulink
+                url="http://code.google.com/apis/youtube/dashboard/">http://code.google.com/apis/youtube/dashboard/</ulink>
+            to obtain a developer key and client ID. The example below demonstrates how to pass the
+            developer key and client ID to the <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube.html">Zend_Gdata_YouTube</ulink>
+            service object.
         </para>
+
         <example id="zend.gdata.youtube.developer_key.example">
-          <title>Passing a Developer Key and ClientID to Zend_Gdata_YouTube</title>
+            <title>Passing a Developer Key and ClientID to Zend_Gdata_YouTube</title>
+
             <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube($httpClient,
                              $applicationId,
                              $clientId,
                              $developerKey);
 ]]></programlisting>
-            </example>
+        </example>
     </sect2>
 
     <sect2 id="zend.gdata.youtube.videos">
         <title>Retrieving public video feeds</title>
 
         <para>
-          The YouTube Data <acronym>API</acronym> provides numerous feeds that return a list of
+            The YouTube Data <acronym>API</acronym> provides numerous feeds that return a list of
             videos, such as standard feeds, related videos, video responses,
             user's uploads, and user's favorites. For example, the
-            user's uploads feed returns all videos uploaded by a specific user.
-            See the <ulink url="http://code.google.com/apis/youtube/reference.html#Video_Feeds">
-            YouTube <acronym>API</acronym> reference guide</ulink> for a detailed list of available feeds.
+            user's uploads feed returns all videos uploaded by a specific user. See the <ulink
+                url="http://code.google.com/apis/youtube/reference.html#Video_Feeds">YouTube
+                <acronym>API</acronym> reference guide</ulink> for a detailed list of available
+            feeds.
         </para>
 
         <sect3 id="zend.gdata.youtube.videos.searching">
@@ -65,9 +79,11 @@ $yt = new Zend_Gdata_YouTube($httpClient,
                 metadata, starting with the 10th video and displaying 20
                 videos per page, ordered by the view count.
             </para>
-        <example id="zend.gdata.youtube.videos.searching.example">
-          <title>Searching for videos</title>
-            <programlisting language="php"><![CDATA[
+
+            <example id="zend.gdata.youtube.videos.searching.example">
+                <title>Searching for videos</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $query = $yt->newVideoQuery();
 $query->videoQuery = 'cat';
@@ -89,12 +105,13 @@ foreach ($videoFeed as $videoEntry) {
             </example>
 
             <para>
-                For more details on the different query parameters, please
-                refer to the <ulink url="http://code.google.com/apis/youtube/reference.html#Searching_for_videos">
-                Reference Guide</ulink>. The available helper functions in
-              <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoQuery.html">
-                <classname>Zend_Gdata_YouTube_VideoQuery</classname></ulink> for each of these parameters are
-                described in more detail in the <ulink url="http://code.google.com/apis/youtube/developers_guide_php.html#SearchingVideos">PHP Developer's Guide</ulink>.
+                For more details on the different query parameters, please refer to the <ulink
+                    url="http://code.google.com/apis/youtube/reference.html#Searching_for_videos">
+                    Reference Guide</ulink>. The available helper functions in <ulink
+                    url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoQuery.html"><classname>Zend_Gdata_YouTube_VideoQuery</classname></ulink>
+                for each of these parameters are described in more detail in the <ulink
+                    url="http://code.google.com/apis/youtube/developers_guide_php.html#SearchingVideos">PHP
+                    Developer's Guide</ulink>.
             </para>
         </sect3>
 
@@ -102,14 +119,16 @@ foreach ($videoFeed as $videoEntry) {
             <title>Searching for videos by categories and tags/keywords</title>
 
             <para>
-                Searching for videos in specific categories is done by
-                generating a <ulink url="http://code.google.com/apis/youtube/reference.html#Category_search">
-                specially formatted <acronym>URL</acronym></ulink>. For example, to search for
+                Searching for videos in specific categories is done by generating a <ulink
+                    url="http://code.google.com/apis/youtube/reference.html#Category_search">specially
+                    formatted <acronym>URL</acronym></ulink>. For example, to search for
                 comedy videos which contain the keyword dog:
             </para>
-             <example id="zend.gdata.youtube.videos.searchingcategories.example">
-          <title>Searching for videos in specific categories</title>
-            <programlisting language="php"><![CDATA[
+
+            <example id="zend.gdata.youtube.videos.searchingcategories.example">
+                <title>Searching for videos in specific categories</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $query = $yt->newVideoQuery();
 $query->category = 'Comedy/dog';
@@ -124,25 +143,30 @@ $videoFeed = $yt->getVideoFeed($query);
             <title>Retrieving standard feeds</title>
 
             <para>
-              The YouTube Data <acronym>API</acronym> has a number of
-                <ulink url="http://code.google.com/apis/youtube/reference.html#Standard_feeds">
-                standard feeds</ulink>. These standard feeds can be retrieved
-                as <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoFeed.html">Zend_Gdata_YouTube_VideoFeed</ulink> objects using the specified
-                <acronym>URL</acronym>s, using the predefined constants within the <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube.html">Zend_Gdata_YouTube</ulink> class
-                (Zend_Gdata_YouTube::STANDARD_TOP_RATED_URI for example) or
+                The YouTube Data <acronym>API</acronym> has a number of <ulink
+                    url="http://code.google.com/apis/youtube/reference.html#Standard_feeds">standard
+                    feeds</ulink>. These standard feeds can be retrieved as <ulink
+                    url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoFeed.html">Zend_Gdata_YouTube_VideoFeed</ulink>
+                objects using the specified <acronym>URL</acronym>s, using the predefined constants
+                within the <ulink
+                    url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube.html">Zend_Gdata_YouTube</ulink>
+                class (Zend_Gdata_YouTube::STANDARD_TOP_RATED_URI for example) or
                 using the predefined helper methods (see code listing below).
             </para>
 
             <para>
                 To retrieve the top rated videos using the helper method:
             </para>
+
             <example id="zend.gdata.youtube.videos.standard.example-1">
-          <title>Retrieving a standard video feed</title>
-            <programlisting language="php"><![CDATA[
+                <title>Retrieving a standard video feed</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $videoFeed = $yt->getTopRatedVideoFeed();
 ]]></programlisting>
             </example>
+
             <para>
                 There are also query parameters to specify the time period
                 over which the standard feed is computed.
@@ -151,23 +175,27 @@ $videoFeed = $yt->getTopRatedVideoFeed();
             <para>
                 For example, to retrieve the top rated videos for today:
             </para>
-<example id="zend.gdata.youtube.videos.standard.example-2">
-          <title>Using a Zend_Gdata_YouTube_VideoQuery to Retrieve Videos</title>
-            <programlisting language="php"><![CDATA[
+
+            <example id="zend.gdata.youtube.videos.standard.example-2">
+                <title>Using a Zend_Gdata_YouTube_VideoQuery to Retrieve Videos</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $query = $yt->newVideoQuery();
 $query->setTime('today');
 $videoFeed = $yt->getTopRatedVideoFeed($query);
 ]]></programlisting>
             </example>
+
             <para>
                 Alternatively, you could just retrieve the feed using the
                 <acronym>URL</acronym>:
             </para>
 
-<example id="zend.gdata.youtube.videos.standard.example-3">
-          <title>Retrieving a video feed by URL</title>
-            <programlisting language="php"><![CDATA[
+            <example id="zend.gdata.youtube.videos.standard.example-3">
+                <title>Retrieving a video feed by URL</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $url = 'http://gdata.youtube.com/feeds/standardfeeds/top_rated?time=today'
 $videoFeed = $yt->getVideoFeed($url);
@@ -183,9 +211,11 @@ $videoFeed = $yt->getVideoFeed($url);
                 using a simple helper method. This example retrieves videos
                 uploaded by the user 'liz'.
             </para>
+
             <example id="zend.gdata.youtube.videos.user.example">
-          <title>Retrieving videos uploaded by a specific user</title>
-            <programlisting language="php"><![CDATA[
+                <title>Retrieving videos uploaded by a specific user</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $videoFeed = $yt->getUserUploads('liz');
 ]]></programlisting>
@@ -200,14 +230,15 @@ $videoFeed = $yt->getUserUploads('liz');
                 using a simple helper method. This example retrieves videos
                 favorited by the user 'liz'.
             </para>
+
             <example id="zend.gdata.youtube.videos.favorites.example">
-          <title>Retrieving a user's favorite videos</title>
-            <programlisting language="php"><![CDATA[
+                <title>Retrieving a user's favorite videos</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $videoFeed = $yt->getUserFavorites('liz');
 ]]></programlisting>
             </example>
-
         </sect3>
 
         <sect3 id="zend.gdata.youtube.videos.responses">
@@ -218,9 +249,11 @@ $videoFeed = $yt->getUserFavorites('liz');
                 using a simple helper method. This example retrieves video
                 response for a video with the ID 'abc123813abc'.
             </para>
+
             <example id="zend.gdata.youtube.videos.responses.example">
-          <title>Retrieving a feed of video responses</title>
-            <programlisting language="php"><![CDATA[
+                <title>Retrieving a feed of video responses</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $videoFeed = $yt->getVideoResponseFeed('abc123813abc');
 ]]></programlisting>
@@ -236,10 +269,11 @@ $videoFeed = $yt->getVideoResponseFeed('abc123813abc');
             several ways. To retrieve the comments for the video with
             the ID 'abc123813abc', use the following code:
         </para>
-            <example id="zend.gdata.youtube.videos.comments.example-1">
-          <title>Retrieving a feed of video comments from a video ID</title>
 
-        <programlisting language="php"><![CDATA[
+        <example id="zend.gdata.youtube.videos.comments.example-1">
+            <title>Retrieving a feed of video comments from a video ID</title>
+
+            <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $commentFeed = $yt->getVideoCommentFeed('abc123813abc');
 
@@ -251,11 +285,13 @@ foreach ($commentFeed as $commentEntry) {
         </example>
 
         <para>
-            Comments can also be retrieved for a video if you have
-            a copy of the <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink> object:
+            Comments can also be retrieved for a video if you have a copy of the <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink>
+            object:
         </para>
-           <example id="zend.gdata.youtube.videos.comments.example-2">
-          <title>Retrieving a Feed of Video Comments from a Zend_Gdata_YouTube_VideoEntry</title>
+
+        <example id="zend.gdata.youtube.videos.comments.example-2">
+            <title>Retrieving a Feed of Video Comments from a Zend_Gdata_YouTube_VideoEntry</title>
 
             <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
@@ -264,8 +300,7 @@ $videoEntry = $yt->getVideoEntry('abc123813abc');
 $commentFeed = $yt->getVideoCommentFeed(null,
                                         $videoEntry->comments->href);
 ]]></programlisting>
-            </example>
-
+        </example>
     </sect2>
 
     <sect2 id="zend.gdata.youtube.playlists">
@@ -284,10 +319,11 @@ $commentFeed = $yt->getVideoCommentFeed(null,
                 the playlists associated with a given user. To retrieve the
                 playlists for the user 'liz':
             </para>
-                       <example id="zend.gdata.youtube.playlists.user.example">
-          <title>Retrieving the playlists of a user</title>
 
-            <programlisting language="php"><![CDATA[
+            <example id="zend.gdata.youtube.playlists.user.example">
+                <title>Retrieving the playlists of a user</title>
+
+                <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $playlistListFeed = $yt->getPlaylistListFeed('liz');
 
@@ -308,9 +344,11 @@ foreach ($playlistListFeed as $playlistEntry) {
                 the videos associated with a given playlist. To retrieve the
                 playlists for a specific playlist entry:
             </para>
-          <example id="zend.gdata.youtube.playlists.special.example">
-          <title>Retrieving a specific playlist</title>
-            <programlisting language="php"><![CDATA[
+
+            <example id="zend.gdata.youtube.playlists.special.example">
+                <title>Retrieving a specific playlist</title>
+
+                <programlisting language="php"><![CDATA[
 $feedUrl = $playlistEntry->getPlaylistVideoFeedUrl();
 $playlistVideoFeed = $yt->getPlaylistVideoFeed($feedUrl);
 ]]></programlisting>
@@ -323,18 +361,19 @@ $playlistVideoFeed = $yt->getPlaylistVideoFeed($feedUrl);
 
         <para>
             A user can have several types of subscriptions: channel
-            subscription, tag subscription, or favorites subscription.
-            A <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_SubscriptionEntry.html">Zend_Gdata_YouTube_SubscriptionEntry</ulink> is used to represent
-            individual subscriptions.
+            subscription, tag subscription, or favorites subscription. A <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_SubscriptionEntry.html">Zend_Gdata_YouTube_SubscriptionEntry</ulink>
+            is used to represent individual subscriptions.
         </para>
 
         <para>
             To retrieve all subscriptions for the user 'liz':
         </para>
+
         <example id="zend.gdata.youtube.subscriptions.example">
-          <title>Retrieving all subscriptions for a user</title>
+            <title>Retrieving all subscriptions for a user</title>
 
-        <programlisting language="php"><![CDATA[
+            <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $subscriptionFeed = $yt->getSubscriptionFeed('liz');
 
@@ -353,10 +392,11 @@ foreach ($subscriptionFeed as $subscriptionEntry) {
             for any YouTube user. To retrieve the profile
             for the user 'liz':
         </para>
-                  <example id="zend.gdata.youtube.profile.example">
-          <title>Retrieving a user's profile</title>
 
-        <programlisting language="php"><![CDATA[
+        <example id="zend.gdata.youtube.profile.example">
+            <title>Retrieving a user's profile</title>
+
+            <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube();
 $userProfile = $yt->getUserProfile('liz');
 echo "username: " . $userProfile->username->text . "\n";
@@ -367,85 +407,103 @@ echo "hometown: " . $userProfile->hometown->text . "\n";
     </sect2>
 
     <sect2 id="zend.gdata.youtube.uploads">
-      <title>Uploading Videos to YouTube</title>
-
-      <para>
-        Please make sure to review the diagrams in the
-        <ulink url="http://code.google.com/apis/youtube/developers_guide_protocol.html#Process_Flows_for_Uploading_Videos">protocol guide</ulink> on code.google.com for a high-level
-        overview of the upload process. Uploading videos can be done in one of
-        two ways: either by uploading the video directly or by sending just the
-        video meta-data and having a user upload the video through an HTML form.
-      </para>
-
-      <para>
-        In order to upload a video directly, you must first construct a new
-        <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink> object and specify some required meta-data
-        The following example shows uploading the Quicktime video "mytestmovie.mov"
-        to YouTube with the following properties:
-      </para>
+        <title>Uploading Videos to YouTube</title>
+
+        <para>
+            Please make sure to review the diagrams in the <ulink
+                url="http://code.google.com/apis/youtube/developers_guide_protocol.html#Process_Flows_for_Uploading_Videos">protocol
+                guide</ulink> on code.google.com for a high-level
+            overview of the upload process. Uploading videos can be done in one of
+            two ways: either by uploading the video directly or by sending just the
+            video meta-data and having a user upload the video through an HTML form.
+        </para>
+
+        <para>
+            In order to upload a video directly, you must first construct a new <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink>
+            object and specify some required meta-data. The following example shows uploading the
+            Quicktime video "mytestmovie.mov" to YouTube with the following properties:
+        </para>
+
         <table id="zend.gdata.youtube.uploads.metadata">
-          <title>Metadata used in the code-sample below</title>
-          <tgroup cols="2" align="left" colsep="1" rowsep="1">
-            <thead>
-              <row>
-                <entry>Property</entry>
-                <entry>Value</entry>
-              </row>
-            </thead>
-            <tbody>
-              <row>
-                <entry>Title</entry>
-                <entry>My Test Movie</entry>
-              </row>
-              <row>
-                <entry>Category</entry>
-                <entry>Autos</entry>
-              </row>
-              <row>
-                <entry>Keywords</entry>
-                <entry>cars, funny</entry>
-              </row>
-              <row>
-                <entry>Description</entry>
-                <entry>My description</entry>
-              </row>
-              <row>
-                <entry>Filename</entry>
-                <entry>mytestmovie.mov</entry>
-              </row>
-              <row>
-                <entry>File <acronym>MIME</acronym> type</entry>
-                <entry>video/quicktime</entry>
-              </row>
-              <row>
-                <entry>Video private?</entry>
-                <entry><constant>FALSE</constant></entry>
-              </row>
-              <row>
-                <entry>Video location</entry>
-                <entry>37, -122 (lat, long)</entry>
-              </row>
-              <row>
-                <entry>Developer Tags</entry>
-                <entry>mydevelopertag, anotherdevelopertag</entry>
-              </row>
-            </tbody>
+            <title>Metadata used in the code-sample below</title>
+
+            <tgroup cols="2" align="left" colsep="1" rowsep="1">
+                <thead>
+                    <row>
+                        <entry>Property</entry>
+                        <entry>Value</entry>
+                    </row>
+                </thead>
+
+                <tbody>
+                    <row>
+                        <entry>Title</entry>
+                        <entry>My Test Movie</entry>
+                    </row>
+
+                    <row>
+                        <entry>Category</entry>
+                        <entry>Autos</entry>
+                    </row>
+
+                    <row>
+                        <entry>Keywords</entry>
+                        <entry>cars, funny</entry>
+                    </row>
+
+                    <row>
+                        <entry>Description</entry>
+                        <entry>My description</entry>
+                    </row>
+
+                    <row>
+                        <entry>Filename</entry>
+                        <entry>mytestmovie.mov</entry>
+                    </row>
+
+                    <row>
+                        <entry>File <acronym>MIME</acronym> type</entry>
+                        <entry>video/quicktime</entry>
+                    </row>
+
+                    <row>
+                        <entry>Video private?</entry>
+                        <entry><constant>FALSE</constant></entry>
+                    </row>
+
+                    <row>
+                        <entry>Video location</entry>
+                        <entry>37, -122 (lat, long)</entry>
+                    </row>
+
+                    <row>
+                        <entry>Developer Tags</entry>
+                        <entry>mydevelopertag, anotherdevelopertag</entry>
+                    </row>
+                </tbody>
             </tgroup>
-      </table>
-      <para>
-        The code below creates a blank <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink> to be uploaded.
-        A <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_App_MediaFileSource.html">Zend_Gdata_App_MediaFileSource</ulink> object is then used to hold the actual video file. Under the hood, the <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_Extension_MediaGroup.html">Zend_Gdata_YouTube_Extension_MediaGroup</ulink> object is used to hold all
-        of the video's meta-data. Our helper methods detailed below allow you to
-        just set the video meta-data without having to worry about the media group object.
-        The $uploadUrl is the location where the new entry gets posted to.
-        This can be specified either with the $userName of the
-        currently authenticated user, or, alternatively, you can simply use the
-        string 'default' to refer to the currently authenticated user.
-      </para>
-          <example id="zend.gdata.youtube.uploads.example">
-          <title>Uploading a video</title>
-
-    <programlisting language="php"><![CDATA[
+        </table>
+
+        <para>
+            The code below creates a blank <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink>
+            to be uploaded. A <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_App_MediaFileSource.html">Zend_Gdata_App_MediaFileSource</ulink>
+            object is then used to hold the actual video file. Under the hood, the <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_Extension_MediaGroup.html">Zend_Gdata_YouTube_Extension_MediaGroup</ulink>
+            object is used to hold all of the video's meta-data. Our helper methods detailed below
+            allow you to just set the video meta-data without having to worry about the media group
+            object. The $uploadUrl is the location where the new entry gets posted to.
+            This can be specified either with the $userName of the
+            currently authenticated user, or, alternatively, you can simply use the
+            string 'default' to refer to the currently authenticated user.
+        </para>
+
+        <example id="zend.gdata.youtube.uploads.example">
+            <title>Uploading a video</title>
+
+            <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube($httpClient);
 $myVideoEntry = new Zend_Gdata_YouTube_VideoEntry();
 
@@ -493,28 +551,32 @@ try {
     echo $e->getMessage();
 }
 ]]></programlisting>
-</example>
-    <para>
-      To upload a video as private, simply use: $myVideoEntry->setVideoPrivate(); prior to
-      performing the upload. $videoEntry->isVideoPrivate() can be used to check whether a video
-      entry is private or not.
-    </para>
-  </sect2>
+        </example>
+
+        <para>
+            To upload a video as private, simply use: $myVideoEntry->setVideoPrivate(); prior to
+            performing the upload. $videoEntry->isVideoPrivate() can be used to check whether a
+            video entry is private or not.
+        </para>
+    </sect2>
 
     <sect2 id="zend.gdata.youtube.uploads.browser">
-      <title>Browser-based upload</title>
-
-      <para>
-        Browser-based uploading is performed almost identically to direct uploading,
-        except that you do not attach a <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_App_MediaFileSource.html">Zend_Gdata_App_MediaFileSource</ulink> object to
-        the <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink> you are constructing. Instead you simply
-        submit all of your video's meta-data to receive back a token element
-        which can be used to construct an HTML upload form.
-      </para>
-          <example id="zend.gdata.youtube.uploads.browser.example-1">
-          <title>Browser-based upload</title>
-
-      <programlisting language="php"><![CDATA[
+        <title>Browser-based upload</title>
+
+        <para>
+            Browser-based uploading is performed almost identically to direct uploading,
+            except that you do not attach a <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_App_MediaFileSource.html">Zend_Gdata_App_MediaFileSource</ulink>
+            object to the <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink>
+            you are constructing. Instead you simply submit all of your video's meta-data to receive
+            back a token element which can be used to construct an HTML upload form.
+        </para>
+
+        <example id="zend.gdata.youtube.uploads.browser.example-1">
+            <title>Browser-based upload</title>
+
+            <programlisting language="php"><![CDATA[
 $yt = new Zend_Gdata_YouTube($httpClient);
 
 $myVideoEntry= new Zend_Gdata_YouTube_VideoEntry();
@@ -530,22 +592,24 @@ $tokenArray = $yt->getFormUploadToken($myVideoEntry, $tokenHandlerUrl);
 $tokenValue = $tokenArray['token'];
 $postUrl = $tokenArray['url'];
 ]]></programlisting>
-      </example>
-    <para>
-      The above code prints out a link and a token that is used to construct an
-      HTML form to display in the user's browser. A simple example form is shown
-      below with $tokenValue representing the content of the returned token element,
-      as shown being retrieved from $myVideoEntry above. In order for the user
-      to be redirected to your website after submitting the form, make sure to
-      append a $nextUrl parameter to the $postUrl above, which functions in the
-      same way as the $next parameter of an AuthSub link. The only difference is
-      that here, instead of a single-use token, a status and an id variable are
-      returned in the <acronym>URL</acronym>.
-    </para>
-          <example id="zend.gdata.youtube.uploads.browser.example-2">
-          <title>Browser-based upload: Creating the HTML form</title>
+        </example>
+
+        <para>
+            The above code prints out a link and a token that is used to construct an
+            HTML form to display in the user's browser. A simple example form is shown
+            below with $tokenValue representing the content of the returned token element,
+            as shown being retrieved from $myVideoEntry above. In order for the user
+            to be redirected to your website after submitting the form, make sure to
+            append a $nextUrl parameter to the $postUrl above, which functions in the
+            same way as the $next parameter of an AuthSub link. The only difference is
+            that here, instead of a single-use token, a status and an id variable are
+            returned in the <acronym>URL</acronym>.
+        </para>
+
+        <example id="zend.gdata.youtube.uploads.browser.example-2">
+            <title>Browser-based upload: Creating the HTML form</title>
 
-      <programlisting language="php"><![CDATA[
+            <programlisting language="php"><![CDATA[
 // place to redirect user after upload
 $nextUrl = 'http://mysite.com/youtube_uploads';
 
@@ -556,23 +620,26 @@ $form = '<form action="'. $postUrl .'?nexturl='. $nextUrl .
         '<input value="Upload Video File" type="submit" />'.
         '</form>';
 ]]></programlisting>
-      </example>
-  </sect2>
+        </example>
+    </sect2>
+
     <sect2 id="zend.gdata.youtube.uploads.status">
-      <title>Checking upload status</title>
-
-      <para>
-        After uploading a video, it will immediately be visible in an
-        authenticated user's uploads feed. However, it will not be public on
-        the site until it has been processed. Videos that have been rejected or
-        failed to upload successfully will also only be in the authenticated
-        user's uploads feed. The following code checks the status of a
-        <ulink url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink> to see if it is not live yet or if it has been rejected.
-      </para>
-      <example id="zend.gdata.youtube.uploads.status.example">
-          <title>Checking video upload status</title>
-
-      <programlisting language="php"><![CDATA[
+        <title>Checking upload status</title>
+
+        <para>
+            After uploading a video, it will immediately be visible in an
+            authenticated user's uploads feed. However, it will not be public on
+            the site until it has been processed. Videos that have been rejected or
+            failed to upload successfully will also only be in the authenticated
+            user's uploads feed. The following code checks the status of a <ulink
+                url="http://framework.zend.com/apidoc/core/Zend_Gdata/Zend_Gdata_YouTube_VideoEntry.html">Zend_Gdata_YouTube_VideoEntry</ulink>
+            to see if it is not live yet or if it has been rejected.
+        </para>
+
+        <example id="zend.gdata.youtube.uploads.status.example">
+            <title>Checking video upload status</title>
+
+            <programlisting language="php"><![CDATA[
 try {
     $control = $videoEntry->getControl();
 } catch (Zend_Gdata_App_Exception $e) {
@@ -595,21 +662,23 @@ if ($control instanceof Zend_Gdata_App_Extension_Control) {
     }
 }
 ]]></programlisting>
-      </example>
-  </sect2>
+        </example>
+    </sect2>
+
     <sect2 id="zend.gdata.youtube.other">
-      <title>Other Functions</title>
-
-      <para>
-        In addition to the functionality described above, the YouTube <acronym>API</acronym>
-        contains many other functions that allow you to modify video meta-data,
-        delete video entries and use the full range of community features on the site.
-        Some of the community features that can be modified through the <acronym>API</acronym> include:
-        ratings, comments, playlists, subscriptions, user profiles, contacts and messages.
-      </para>
-      <para>
-        Please refer to the full documentation available in the
-        <ulink url="http://code.google.com/apis/youtube/developers_guide_php.html">PHP Developer's Guide</ulink> on code.google.com.
-      </para>
+        <title>Other Functions</title>
+
+        <para>
+            In addition to the functionality described above, the YouTube <acronym>API</acronym>
+            contains many other functions that allow you to modify video meta-data,
+            delete video entries and use the full range of community features on the site. Some of
+            the community features that can be modified through the <acronym>API</acronym> include:
+            ratings, comments, playlists, subscriptions, user profiles, contacts and messages.
+        </para>
+        <para>
+            Please refer to the full documentation available in the <ulink
+                url="http://code.google.com/apis/youtube/developers_guide_php.html">PHP Developer's
+                Guide</ulink> on code.google.com.
+        </para>
     </sect2>
 </sect1>

+ 140 - 53
documentation/manual/en/module_specs/Zend_Http_Client-Adapters.xml

@@ -5,6 +5,7 @@
 
     <sect2 id="zend.http.client.adapters.overview">
         <title>Overview</title>
+
         <para>
             <classname>Zend_Http_Client</classname> is based on a connection adapter design. The
             connection adapter is the object in charge of performing the
@@ -15,25 +16,30 @@
             without the need to extend or replace the entire <acronym>HTTP</acronym> client
             class, and with the same interface.
         </para>
+
         <para>
             Currently, the <classname>Zend_Http_Client</classname> class provides four built-in
             connection adapters:
+
             <itemizedlist>
                 <listitem>
                     <para>
                         <classname>Zend_Http_Client_Adapter_Socket</classname> (default)
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <classname>Zend_Http_Client_Adapter_Proxy</classname>
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <classname>Zend_Http_Client_Adapter_Curl</classname>
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <classname>Zend_Http_Client_Adapter_Test</classname>
@@ -41,6 +47,7 @@
                 </listitem>
             </itemizedlist>
         </para>
+
         <para>
             The <classname>Zend_Http_Client</classname> object's adapter connection adapter is set
             using the 'adapter' configuration option. When instantiating the
@@ -54,19 +61,23 @@
 
     <sect2 id="zend.http.client.adapters.socket">
         <title>The Socket Adapter</title>
+
         <para>
-            The default connection adapter is the <classname>Zend_Http_Client_Adapter_Socket</classname>
-            adapter - this adapter will be used unless you explicitly set the
-            connection adapter. The Socket adapter is based on <acronym>PHP</acronym>'s built-in
-            fsockopen() function, and does not require any special extensions or
-            compilation flags.
+            The default connection adapter is the
+            <classname>Zend_Http_Client_Adapter_Socket</classname> adapter - this adapter will be
+            used unless you explicitly set the connection adapter. The Socket adapter is based on
+            <acronym>PHP</acronym>'s built-in fsockopen() function, and does not require any special
+            extensions or compilation flags.
         </para>
+
         <para>
             The Socket adapter allows several extra configuration options that
             can be set using <classname>Zend_Http_Client->setConfig()</classname> or
             passed to the client constructor.
+
             <table id="zend.http.client.adapter.socket.configuration.table">
                 <title>Zend_Http_Client_Adapter_Socket configuration parameters</title>
+
                 <tgroup cols="4">
                     <thead>
                         <row>
@@ -76,28 +87,45 @@
                             <entry>Default Value</entry>
                         </row>
                     </thead>
+
                     <tbody>
                         <row>
                             <entry>persistent</entry>
-                            <entry>Whether to use persistent <acronym>TCP</acronym> connections</entry>
+
+                            <entry>
+                                Whether to use persistent <acronym>TCP</acronym> connections
+                            </entry>
+
                             <entry>boolean</entry>
                             <entry><constant>FALSE</constant></entry>
                         </row>
+
                         <row>
                             <entry>ssltransport</entry>
                             <entry>SSL transport layer (eg. 'sslv2', 'tls')</entry>
                             <entry>string</entry>
                             <entry>ssl</entry>
                         </row>
+
                         <row>
                             <entry>sslcert</entry>
-                            <entry>Path to a <acronym>PEM</acronym> encoded <acronym>SSL</acronym> certificate</entry>
+
+                            <entry>
+                                Path to a <acronym>PEM</acronym> encoded <acronym>SSL</acronym>
+                                certificate
+                            </entry>
+
                             <entry>string</entry>
                             <entry><constant>NULL</constant></entry>
                         </row>
+
                         <row>
                             <entry>sslpassphrase</entry>
-                            <entry>Passphrase for the <acronym>SSL</acronym> certificate file</entry>
+
+                            <entry>
+                                Passphrase for the <acronym>SSL</acronym> certificate file
+                            </entry>
+
                             <entry>string</entry>
                             <entry><constant>NULL</constant></entry>
                         </row>
@@ -107,12 +135,14 @@
 
             <note>
                 <title>Persistent TCP Connections</title>
+
                 <para>
                     Using persistent <acronym>TCP</acronym> connections can potentially speed up
                     <acronym>HTTP</acronym> requests - but in most use cases, will have little
                     positive effect and might overload the <acronym>HTTP</acronym> server you are
                     connecting to.
                 </para>
+
                 <para>
                     It is recommended to use persistent <acronym>TCP</acronym> connections only if
                     you connect to the same server very frequently, and are
@@ -121,6 +151,7 @@
                     to benchmark the effect of persistent connections on both
                     the client speed and server load before using this option.
                 </para>
+
                 <para>
                     Additionally, when using persistent connections it is
                     recommended to enable Keep-Alive <acronym>HTTP</acronym> requests as described
@@ -132,21 +163,26 @@
 
             <note>
                 <title>HTTPS SSL Stream Parameters</title>
+
                 <para>
                     <code>ssltransport, sslcert</code> and <code>sslpassphrase</code>
                     are only relevant when connecting using <acronym>HTTPS</acronym>.
                 </para>
+
                 <para>
                     While the default <acronym>SSL</acronym> settings should work for most
                     applications, you might need to change them if the server
                     you are connecting to requires special client setup. If so,
                     you should read the sections about <acronym>SSL</acronym> transport layers and
-                    options <ulink url="http://www.php.net/manual/en/transports.php#transports.inet">here</ulink>.
+                    options <ulink
+                        url="http://www.php.net/manual/en/transports.php#transports.inet">here</ulink>.
                 </para>
             </note>
         </para>
+
         <example id="zend.http.client.adapters.socket.example-1">
             <title>Changing the HTTPS transport layer</title>
+
             <programlisting language="php"><![CDATA[
 // Set the configuration parameters
 $config = array(
@@ -161,51 +197,62 @@ $client = new Zend_Http_Client('https://www.example.com', $config);
 $response = $client->request();
 ]]></programlisting>
         </example>
+
         <para>
             The result of the example above will be similar to opening a <acronym>TCP</acronym>
             connection using the following <acronym>PHP</acronym> command:
         </para>
+
         <para>
             <methodname>fsockopen('tls://www.example.com', 443)</methodname>
         </para>
 
         <sect3 id="zend.http.client.adapters.socket.streamcontext">
             <title>Customizing and accessing the Socket adapter stream context</title>
+
             <para>
-                Starting from Zend Framework 1.9, <classname>Zend_Http_Client_Adapter_Socket</classname>
-                provides direct access to the underlying <ulink url="http://php.net/manual/en/stream.contexts.php">stream context</ulink>
-                used to connect to the remote server. This allows the user to pass
-                specific options and parameters to the <acronym>TCP</acronym> stream, and to the <acronym>SSL</acronym> wrapper in
-                case of <acronym>HTTPS</acronym> connections.
+                Starting from Zend Framework 1.9,
+                <classname>Zend_Http_Client_Adapter_Socket</classname> provides direct access to the
+                underlying <ulink
+                    url="http://php.net/manual/en/stream.contexts.php">stream context</ulink> used
+                to connect to the remote server. This allows the user to pass specific options and
+                parameters to the <acronym>TCP</acronym> stream, and to the <acronym>SSL</acronym>
+                wrapper in case of <acronym>HTTPS</acronym> connections.
             </para>
 
             <para>
-                You can access the stream context using the following methods of <classname>Zend_Http_Client_Adapter_Socket</classname>:
+                You can access the stream context using the following methods of
+                <classname>Zend_Http_Client_Adapter_Socket</classname>:
+
                 <itemizedlist>
                     <listitem>
                         <para>
                             <firstterm><methodname>setStreamContext($context)</methodname></firstterm>
                             Sets the stream context to be used by the adapter. Can accept either
-                            a stream context resource created using the
-                            <ulink url="http://php.net/manual/en/function.stream-context-create.php"><methodname>stream_context_create()</methodname></ulink>
-                            <acronym>PHP</acronym> function, or an array of stream context options, in the same format provided to this function.
-                            Providing an array will create a new stream context using these options, and set it.
+                            a stream context resource created using the <ulink
+                                url="http://php.net/manual/en/function.stream-context-create.php"><methodname>stream_context_create()</methodname></ulink>
+                            <acronym>PHP</acronym> function, or an array of stream context options,
+                            in the same format provided to this function. Providing an array will
+                            create a new stream context using these options, and set it.
                         </para>
                     </listitem>
+
                     <listitem>
                         <para>
                             <firstterm><methodname>getStreamContext()</methodname></firstterm>
                             Get the stream context of the adapter. If no stream context was set,
                             will create a default stream context and return it. You can then set
-                            or get the value of different context options using regular <acronym>PHP</acronym> stream
-                            context functions.
+                            or get the value of different context options using regular
+                            <acronym>PHP</acronym> stream context functions.
                         </para>
                     </listitem>
                 </itemizedlist>
             </para>
+
             <example id="zend.http.client.adapters.socket.streamcontext.example-1">
-            <title>Setting stream context options for the Socket adapter</title>
-            <programlisting language="php"><![CDATA[
+                <title>Setting stream context options for the Socket adapter</title>
+
+                <programlisting language="php"><![CDATA[
 // Array of options
 $options = array(
     'socket' => array(
@@ -246,26 +293,28 @@ $response = $client->request();
 $opts = stream_context_get_options($adapter->getStreamContext());
 echo $opts['ssl']['peer_certificate'];
 ]]></programlisting>
-        </example>
+            </example>
 
-        <note>
-            <para>
-                Note that you must set any stream context options before using the adapter
-                to preform actual requests. If no context is set before preforming <acronym>HTTP</acronym> requests
-                with the Socket adapter, a default stream context will be created. This context
-                resource could be accessed after preforming any requests using the
-                <methodname>getStreamContext()</methodname> method.
-            </para>
-        </note>
+            <note>
+                <para>
+                    Note that you must set any stream context options before using the adapter
+                    to preform actual requests. If no context is set before preforming
+                    <acronym>HTTP</acronym> requests with the Socket adapter, a default stream
+                    context will be created. This context resource could be accessed after
+                    preforming any requests using the <methodname>getStreamContext()</methodname>
+                    method.
+                </para>
+            </note>
         </sect3>
     </sect2>
 
     <sect2 id="zend.http.client.adapters.proxy">
         <title>The Proxy Adapter</title>
+
         <para>
-            The <classname>Zend_Http_Client_Adapter_Proxy</classname> adapter is similar to the default
-            Socket adapter - only the connection is made through an <acronym>HTTP</acronym> proxy
-            server instead of a direct connection to the target server. This
+            The <classname>Zend_Http_Client_Adapter_Proxy</classname> adapter is similar to the
+            default Socket adapter - only the connection is made through an <acronym>HTTP</acronym>
+            proxy server instead of a direct connection to the target server. This
             allows usage of <classname>Zend_Http_Client</classname> behind proxy servers - which is
             sometimes needed for security or performance reasons.
         </para>
@@ -273,8 +322,10 @@ echo $opts['ssl']['peer_certificate'];
         <para>
             Using the Proxy adapter requires several additional configuration
             parameters to be set, in addition to the default 'adapter' option:
+
             <table id="zend.http.client.adapters.proxy.table">
                 <title>Zend_Http_Client configuration parameters</title>
+
                 <tgroup cols="4">
                     <thead>
                         <row>
@@ -284,6 +335,7 @@ echo $opts['ssl']['peer_certificate'];
                             <entry>Example Value</entry>
                         </row>
                     </thead>
+
                     <tbody>
                         <row>
                             <entry>proxy_host</entry>
@@ -291,24 +343,28 @@ echo $opts['ssl']['peer_certificate'];
                             <entry>string</entry>
                             <entry>'proxy.myhost.com' or '10.1.2.3'</entry>
                         </row>
+
                         <row>
                             <entry>proxy_port</entry>
                             <entry>Proxy server <acronym>TCP</acronym> port</entry>
                             <entry>integer</entry>
                             <entry>8080 (default) or 81</entry>
                         </row>
+
                         <row>
                             <entry>proxy_user</entry>
                             <entry>Proxy user name, if required</entry>
                             <entry>string</entry>
                             <entry>'shahar' or '' for none (default)</entry>
                         </row>
+
                         <row>
                             <entry>proxy_pass</entry>
                             <entry>Proxy password, if required</entry>
                             <entry>string</entry>
                             <entry>'secret' or '' for none (default)</entry>
                         </row>
+
                         <row>
                             <entry>proxy_auth</entry>
                             <entry>Proxy <acronym>HTTP</acronym> authentication type</entry>
@@ -319,26 +375,31 @@ echo $opts['ssl']['peer_certificate'];
                 </tgroup>
             </table>
         </para>
+
         <para>
             proxy_host should always be set - if it is not set, the client will
-            fall back to a direct connection using <classname>Zend_Http_Client_Adapter_Socket</classname>.
-            proxy_port defaults to '8080' - if your proxy listens on a different
-            port you must set this one as well.
+            fall back to a direct connection using
+            <classname>Zend_Http_Client_Adapter_Socket</classname>. proxy_port defaults to '8080' -
+            if your proxy listens on a different port you must set this one as well.
         </para>
+
         <para>
             proxy_user and proxy_pass are only required if your proxy server
             requires you to authenticate. Providing these will add a 'Proxy-Authentication'
             header to the request. If your proxy does not require authentication,
             you can leave these two options out.
         </para>
+
         <para>
             proxy_auth sets the proxy authentication type, if your proxy server
             requires authentication. Possibly values are similar to the ones
             accepted by the Zend_Http_Client::setAuth() method. Currently, only
             basic authentication (Zend_Http_Client::AUTH_BASIC) is supported.
         </para>
+
         <example id="zend.http.client.adapters.proxy.example-1">
             <title>Using Zend_Http_Client behind a proxy server</title>
+
             <programlisting language="php"><![CDATA[
 // Set the configuration parameters
 $config = array(
@@ -355,6 +416,7 @@ $client = new Zend_Http_Client('http://www.example.com', $config);
 // Continue working...
 ]]></programlisting>
         </example>
+
         <para>
             As mentioned, if proxy_host is not set or is set to a blank string,
             the connection will fall back to a regular direct connection. This
@@ -364,15 +426,18 @@ $client = new Zend_Http_Client('http://www.example.com', $config);
 
         <note>
             <para>
-                Since the proxy adapter inherits from <classname>Zend_Http_Client_Adapter_Socket</classname>,
-                you can use the stream context access method (see <xref linkend="zend.http.client.adapters.socket.streamcontext" />)
-                to set stream context options on Proxy connections as demonstrated above.
+                Since the proxy adapter inherits from
+                <classname>Zend_Http_Client_Adapter_Socket</classname>, you can use the stream
+                context access method (see <xref
+                    linkend="zend.http.client.adapters.socket.streamcontext" />) to set stream
+                context options on Proxy connections as demonstrated above.
             </para>
         </note>
     </sect2>
 
     <sect2 id="zend.http.client.adapters.curl">
         <title>The cURL Adapter</title>
+
         <para>
             cURL is a standard <acronym>HTTP</acronym> client library that is distributed with many
             operating systems and can be used in <acronym>PHP</acronym> via the cURL extension. It
@@ -384,6 +449,7 @@ $client = new Zend_Http_Client('http://www.example.com', $config);
 
         <example id="zend.http.client.adapters.curl.example-1">
             <title>Setting cURL options</title>
+
             <programlisting language="php"><![CDATA[
 $config = array(
     'adapter'   => 'Zend_Http_Client_Adapter_Curl',
@@ -396,8 +462,8 @@ $client = new Zend_Http_Client($uri, $config);
         <para>
             By default the cURL adapter is configured to behave exactly like
             the Socket Adapter and it also accepts the same configuration parameters
-            as the Socket and Proxy adapters. You can also change the cURL options by either specifying
-            the 'curloptions' key in the constructor of the adapter or by calling
+            as the Socket and Proxy adapters. You can also change the cURL options by either
+            specifying the 'curloptions' key in the constructor of the adapter or by calling
             <methodname>setCurlOption($name, $value)</methodname>. The <varname>$name</varname> key
             corresponds to the CURL_* constants of the cURL extension. You can
             get access to the Curl handle by calling <code>$adapter->getHandle();</code>
@@ -407,7 +473,8 @@ $client = new Zend_Http_Client($uri, $config);
             <title>Transfering Files by Handle</title>
 
             <para>
-                You can use cURL to transfer very large files over <acronym>HTTP</acronym> by filehandle.
+                You can use cURL to transfer very large files over <acronym>HTTP</acronym> by
+                filehandle.
             </para>
 
             <programlisting language="php"><![CDATA[
@@ -430,11 +497,14 @@ $client->request("PUT");
 
     <sect2 id="zend.http.client.adapters.test">
         <title>The Test Adapter</title>
+
         <para>
-            Sometimes, it is very hard to test code that relies on <acronym>HTTP</acronym> connections.
-            For example, testing an application that pulls an <acronym>RSS</acronym> feed from a remote
-            server will require a network connection, which is not always available.
+            Sometimes, it is very hard to test code that relies on <acronym>HTTP</acronym>
+            connections. For example, testing an application that pulls an <acronym>RSS</acronym>
+            feed from a remote server will require a network connection, which is not always
+            available.
         </para>
+
         <para>
             For this reason, the <classname>Zend_Http_Client_Adapter_Test</classname> adapter is
             provided. You can write your application to use <classname>Zend_Http_Client</classname>,
@@ -443,15 +513,19 @@ $client->request("PUT");
             mock object), allowing you to run tests without actually
             performing server connections.
         </para>
+
         <para>
             The <classname>Zend_Http_Client_Adapter_Test</classname> adapter provides an additional
             method, setResponse() method. This method takes one parameter,
-            which represents an <acronym>HTTP</acronym> response as either text or a <classname>Zend_Http_Response</classname>
-            object. Once set, your Test adapter will always return this response,
-            without even performing an actual <acronym>HTTP</acronym> request.
+            which represents an <acronym>HTTP</acronym> response as either text or a
+            <classname>Zend_Http_Response</classname> object. Once set, your Test adapter will
+            always return this response, without even performing an actual <acronym>HTTP</acronym>
+            request.
         </para>
+
         <example id="zend.http.client.adapters.test.example-1">
             <title>Testing Against a Single HTTP Response Stub</title>
+
             <programlisting language="php"><![CDATA[
 // Instantiate a new adapter and client
 $adapter = new Zend_Http_Client_Adapter_Test();
@@ -478,6 +552,7 @@ $response = $client->request('GET');
 // .. continue parsing $response..
 ]]></programlisting>
         </example>
+
         <para>
             The above example shows how you can preset your <acronym>HTTP</acronym> client to
             return the response you need. Then, you can continue testing your
@@ -493,8 +568,10 @@ $response = $client->request('GET');
             opportunity to set the next response(s) your program might need
             before returning to the caller.
         </para>
+
         <example id="zend.http.client.adapters.test.example-2">
             <title>Testing Against Multiple HTTP Response Stubs</title>
+
             <programlisting language="php"><![CDATA[
 // Instantiate a new adapter and client
 $adapter = new Zend_Http_Client_Adapter_Test();
@@ -527,18 +604,21 @@ $adapter->addResponse(
 // being tested and then test your object's behavior below
 ]]></programlisting>
         </example>
+
         <para>
             The setResponse() method clears any responses in the
             <classname>Zend_Http_Client_Adapter_Test</classname>'s buffer and sets the
             first response that will be returned. The addResponse()
             method will add successive responses.
         </para>
+
         <para>
             The responses will be replayed in the order that they
             were added. If more requests are made than the number
             of responses stored, the responses will cycle again
             in order.
         </para>
+
         <para>
             In the example above, the adapter is configured to test your
             object's behavior when it encounters a 302 redirect. Depending on
@@ -551,6 +631,7 @@ $adapter->addResponse(
             the <acronym>HTTP</acronym> client containing the adapter into your object under test
             and test its behavior.
         </para>
+
         <para>
             If you need the adapter to fail on demand you can use
             <methodname>setNextRequestWillFail($flag)</methodname>. The method will cause the next
@@ -559,8 +640,10 @@ $adapter->addResponse(
             when your application caches content from an external site (in case the site goes down)
             and you want to test this feature.
         </para>
+
         <example id="zend.http.client.adapters.test.example-3">
             <title>Forcing the adapter to fail</title>
+
             <programlisting language="php"><![CDATA[
 // Instantiate a new adapter and client
 $adapter = new Zend_Http_Client_Adapter_Test();
@@ -586,20 +669,24 @@ try {
 
     <sect2 id="zend.http.client.adapters.extending">
         <title>Creating your own connection adapters</title>
+
         <para>
             You can create your own connection adapters and use them. You could, for
             example, create a connection adapter that uses persistent sockets,
             or a connection adapter with caching abilities, and use them as
             needed in your application.
         </para>
+
         <para>
             In order to do so, you must create your own adapter class that implements
-            the <classname>Zend_Http_Client_Adapter_Interface</classname> interface. The following example
-            shows the skeleton of a user-implemented adapter class. All the public
+            the <classname>Zend_Http_Client_Adapter_Interface</classname> interface. The following
+            example shows the skeleton of a user-implemented adapter class. All the public
             functions defined in this example must be defined in your adapter as well:
         </para>
+
         <example id="zend.http.client.adapters.extending.example-1">
             <title>Creating your own connection adapter</title>
+
             <programlisting language="php"><![CDATA[
 class MyApp_Http_Client_Adapter_BananaProtocol
     implements Zend_Http_Client_Adapter_Interface

+ 70 - 20
documentation/manual/en/module_specs/Zend_Http_Client-Advanced.xml

@@ -5,11 +5,13 @@
 
     <sect2 id="zend.http.client.redirections">
         <title>HTTP Redirections</title>
+
         <para>
-            By default, <classname>Zend_Http_Client</classname> automatically handles <acronym>HTTP</acronym> redirections,
-            and will follow up to 5 redirections. This can be changed by setting
-            the 'maxredirects' configuration parameter.
+            By default, <classname>Zend_Http_Client</classname> automatically handles
+            <acronym>HTTP</acronym> redirections, and will follow up to 5 redirections. This can be
+            changed by setting the 'maxredirects' configuration parameter.
         </para>
+
         <para>
             According to the HTTP/1.1 RFC, HTTP 301 and 302 responses should be
             treated by the client by resending the same request to the
@@ -22,6 +24,7 @@
             parameter to boolean <constant>TRUE</constant>:
             <example id="zend.http.client.redirections.example-1">
                 <title>Forcing RFC 2616 Strict Redirections on 301 and 302 Responses</title>
+
                 <programlisting language="php"><![CDATA[
 // Strict Redirections
 $client->setConfig(array('strictredirects' => true));
@@ -31,6 +34,7 @@ $client->setConfig(array('strictredirects' => false));
 ]]></programlisting>
             </example>
         </para>
+
         <para>
             You can always get the number of redirections done after sending a
             request using the getRedirectionsCount() method.
@@ -39,13 +43,16 @@ $client->setConfig(array('strictredirects' => false));
 
     <sect2 id="zend.http.client.cookies">
         <title>Adding Cookies and Using Cookie Persistence</title>
+
         <para>
             Zend_Http_Client provides an easy interface for adding cookies
             to your request, so that no direct header modification is
             required. This is done using the setCookie() method. This method
             can be used in several ways:
+
             <example id="zend.http.client.cookies.example-1">
                 <title>Setting Cookies Using setCookie()</title>
+
                 <programlisting language="php"><![CDATA[
 // Easy and simple: by providing a cookie name and cookie value
 $client->setCookie('flavor', 'chocolate chips');
@@ -59,9 +66,11 @@ $cookie = Zend_Http_Cookie::fromString('flavor=chocolate%20chips');
 $client->setCookie($cookie);
 ]]></programlisting>
             </example>
+
             For more information about Zend_Http_Cookie objects, see
             <xref linkend="zend.http.cookies" />.
         </para>
+
         <para>
             Zend_Http_Client also provides the means for cookie stickiness -
             that is having the client internally store all sent and received
@@ -69,8 +78,10 @@ $client->setCookie($cookie);
             is useful, for example when you need to log in to a remote site
             first and receive and authentication or session ID cookie before
             sending further requests.
+
             <example id="zend.http.client.cookies.example-2">
                 <title>Enabling Cookie Stickiness</title>
+
                 <programlisting language="php"><![CDATA[
 // To turn cookie stickiness on, set a Cookie Jar
 $client->setCookieJar();
@@ -90,6 +101,7 @@ $client->setUri('http://example.com/read_member_news.php');
 $client->request('GET');
 ]]></programlisting>
             </example>
+
             For more information about the Zend_Http_CookieJar class, see
             <xref linkend="zend.http.cookies.cookiejar" />.
         </para>
@@ -97,12 +109,15 @@ $client->request('GET');
 
     <sect2 id="zend.http.client.custom_headers">
         <title>Setting Custom Request Headers</title>
+
         <para>
             Setting custom headers can be done by using the setHeaders() method.
             This method is quite diverse and can be used in several ways, as
             the following example shows:
+
             <example id="zend.http.client.custom_headers.example-1">
                 <title>Setting A Single Custom Request Header</title>
+
                 <programlisting language="php"><![CDATA[
 // Setting a single header, overwriting any previous value
 $client->setHeaders('Host', 'www.example.com');
@@ -119,11 +134,14 @@ $client->setHeaders('Cookie', array(
 ]]></programlisting>
             </example>
         </para>
+
         <para>
             setHeader() can also be easily used to set multiple headers in one
             call, by providing an array of headers as a single parameter:
+
             <example id="zend.http.client.custom_headers.example-2">
                 <title>Setting Multiple Custom Request Headers</title>
+
                 <programlisting language="php"><![CDATA[
 // Setting multiple headers, overwriting any previous value
 $client->setHeaders(array(
@@ -175,6 +193,7 @@ $client->setFileUpload('/tmp/Backup.tar.gz', 'bufile');
 $client->request('POST');
 ]]></programlisting>
             </example>
+
             In the first example, the $text variable is uploaded and will be
             available as $_FILES['upload'] on the server side. In the second
             example, the existing file /tmp/Backup.tar.gz is uploaded to the
@@ -182,8 +201,10 @@ $client->request('POST');
             will be guesses automatically if possible - and if not, the content
             type will be set to 'application/octet-stream'.
         </para>
+
         <note>
             <title>Uploading files</title>
+
             <para>
                 When uploading files, the <acronym>HTTP</acronym> request content-type is
                 automatically set to multipart/form-data. Keep in mind that
@@ -193,8 +214,10 @@ $client->request('POST');
             </para>
         </note>
     </sect2>
+
     <sect2 id="zend.http.client.raw_post_data">
         <title>Sending Raw POST Data</title>
+
         <para>
             You can use a Zend_Http_Client to send raw POST data using the
             setRawData() method. This method takes two parameters: the first
@@ -202,8 +225,10 @@ $client->request('POST');
             parameter is the content-type of the data. While this parameter is
             optional, you should usually set it before sending the request -
             either using setRawData(), or with another method: setEncType().
+
             <example id="zend.http.client.raw_post_data.example-1">
                 <title>Sending Raw POST Data</title>
+
                 <programlisting language="php"><![CDATA[
 $xml = '<book>' .
        '  <title>Islands in the Stream</title>' .
@@ -217,11 +242,14 @@ $client->setRawData($xml, 'text/xml')->request('POST');
 $client->setRawData($xml)->setEncType('text/xml')->request('POST');
 ]]></programlisting>
             </example>
+
             The data should be available on the server side through PHP's
             $HTTP_RAW_POST_DATA variable or through the php://input stream.
         </para>
+
         <note>
             <title>Using raw POST data</title>
+
             <para>
                 Setting raw POST data for a request will override any POST
                 parameters or file uploads. You should not try to use both on
@@ -233,6 +261,7 @@ $client->setRawData($xml)->setEncType('text/xml')->request('POST');
 
     <sect2 id="zend.http.client.http_authentication">
         <title>HTTP Authentication</title>
+
         <para>
             Currently, Zend_Http_Client only supports basic HTTP authentication.
             This feature is utilized using the <methodname>setAuth()</methodname>
@@ -242,8 +271,10 @@ $client->setRawData($xml)->setEncType('text/xml')->request('POST');
             authentication type parameter. As mentioned, currently only basic
             authentication is supported (digest authentication support is
             planned).
+
             <example id="zend.http.client.http_authentication.example-1">
                 <title>Setting HTTP Authentication User and Password</title>
+
                 <programlisting language="php"><![CDATA[
 // Using basic authentication
 $client->setAuth('shahar', 'myPassword!', Zend_Http_Client::AUTH_BASIC);
@@ -260,6 +291,7 @@ $client->setUri('http://christer:secret@example.com');
 
     <sect2 id="zend.http.client.multiple_requests">
         <title>Sending Multiple Requests With the Same Client</title>
+
         <para>
             <classname>Zend_Http_Client</classname> was also designed specifically to handle several
             consecutive requests with the same object. This is useful in cases
@@ -267,6 +299,7 @@ $client->setUri('http://christer:secret@example.com');
             when accessing a specific <acronym>HTTP</acronym> resource requires logging in and
             obtaining a session cookie, for example.
         </para>
+
         <para>
             When performing several requests to the same host, it is highly
             recommended to enable the 'keepalive' configuration flag. This way,
@@ -275,6 +308,7 @@ $client->setUri('http://christer:secret@example.com');
             object is destroyed. This prevents the overhead of opening and
             closing <acronym>TCP</acronym> connections to the server.
         </para>
+
         <para>
             When you perform several requests with the same client, but want
             to make sure all the request-specific parameters are cleared, you
@@ -282,8 +316,10 @@ $client->setUri('http://christer:secret@example.com');
             POST parameters, request body and request-specific headers are
             reset and are not reused in the next request.
         </para>
+
         <note>
             <title>Resetting parameters</title>
+
             <para>
                 Note that non-request specific headers are not reset by default
                 when the <methodname>resetParameters()</methodname> method is used.
@@ -291,11 +327,13 @@ $client->setUri('http://christer:secret@example.com');
                 allows you to set-and-forget headers like 'Accept-language' and
                 'Accept-encoding'
             </para>
+
             <para>
-            To clean all headers and other data except for URI and method, use
-            <methodname>resetParameters(true)</methodname>.
+                To clean all headers and other data except for URI and method, use
+                <methodname>resetParameters(true)</methodname>.
             </para>
         </note>
+
         <para>
             Another feature designed specifically for consecutive requests is
             the Cookie Jar object. Cookie Jars allow you to automatically save
@@ -304,6 +342,7 @@ $client->setUri('http://christer:secret@example.com');
             through an authentication request before sending the actual data
             fetching request.
         </para>
+
         <para>
             If your application requires one authentication request per user,
             and consecutive requests might be performed in more than one script
@@ -311,8 +350,10 @@ $client->setUri('http://christer:secret@example.com');
             object in the user's session. This way, you will only need to
             authenticate the user once every session.
         </para>
+
         <example id="zend.http.client.multiple_requests.example-1">
             <title>Performing consecutive requests with one client</title>
+
             <programlisting language="php"><![CDATA[
 // First, instantiate the client
 $client = new Zend_Http_Client('http://www.example.com/fetchdata.php', array(
@@ -348,28 +389,35 @@ $_SESSION['cookiejar'] = $client->getCookieJar();
 ]]></programlisting>
         </example>
     </sect2>
+
     <sect2 id="zend.http.client.streaming">
         <title>Data Streaming</title>
+
         <para>
-            By default, <classname>Zend_Http_Client</classname> accepts and returns data as PHP strings.
-            However, in many cases there are big files to be sent or received, thus keeping them
-            in memory might be unnecessary or too expensive. For these cases, <classname>Zend_Http_Client</classname>
-            supports reading data from files (and in general, PHP streams) and writing data to files (streams).
+            By default, <classname>Zend_Http_Client</classname> accepts and returns data as PHP
+            strings. However, in many cases there are big files to be sent or received, thus keeping
+            them in memory might be unnecessary or too expensive. For these cases,
+            <classname>Zend_Http_Client</classname> supports reading data from files (and in
+            general, PHP streams) and writing data to files (streams).
         </para>
+
         <para>
             In order to use stream to pass data to <classname>Zend_Http_Client</classname>,
-            use <methodname>setRawData()</methodname> method with data argument being stream resource
-            (e.g., result of <methodname>fopen()</methodname>).
+            use <methodname>setRawData()</methodname> method with data argument being stream
+            resource (e.g., result of <methodname>fopen()</methodname>).
+
             <example id="zend.http.client.streaming.example-1">
                 <title>Sending file to HTTP server with streaming</title>
+
                 <programlisting language="php"><![CDATA[
 $fp = fopen("mybigfile.zip", "r");
 $client->setRawData($fp, 'application/zip')->request('PUT');
 ]]></programlisting>
             </example>
         </para>
+
         <para>
-        Only PUT requests currently support sending streams to HTTP server.
+            Only PUT requests currently support sending streams to HTTP server.
         </para>
 
         <para>
@@ -381,17 +429,20 @@ $client->setRawData($fp, 'application/zip')->request('PUT');
         </para>
 
         <para>
-        When using streaming, <methodname>request()</methodname> method will return object of class
-        <classname>Zend_Http_Client_Response_Stream</classname>, which has two useful methods:
-        <methodname>getStreamName()</methodname> will return the name of the file where the response is stored,
-        and <methodname>getStream()</methodname> will return stream from which the response could be read.
+            When using streaming, <methodname>request()</methodname> method will return object of
+            class <classname>Zend_Http_Client_Response_Stream</classname>, which has two useful
+            methods: <methodname>getStreamName()</methodname> will return the name of the file where
+            the response is stored, and <methodname>getStream()</methodname> will return stream from
+            which the response could be read.
         </para>
 
         <para>
-        You can either write the response to pre-defined file, or use temporary file for storing it and
-        send it out or write it to another file using regular stream functions.
-        <example id="zend.http.client.streaming.example-2">
+            You can either write the response to pre-defined file, or use temporary file for storing
+            it and send it out or write it to another file using regular stream functions.
+
+            <example id="zend.http.client.streaming.example-2">
                 <title>Receiving file from HTTP server with streaming</title>
+
                 <programlisting language="php"><![CDATA[
 $client->setStreaming(); // will use temp file
 $response = $client->request('GET');
@@ -405,6 +456,5 @@ $client->setStreaming("my/downloads/myfile)->request('GET');
 ]]></programlisting>
             </example>
         </para>
-
     </sect2>
 </sect1>

+ 59 - 11
documentation/manual/en/module_specs/Zend_Http_Client.xml

@@ -2,24 +2,29 @@
 <!-- Reviewed: no -->
 <sect1 id="zend.http.client">
     <title>Introduction</title>
+
     <para>
         <classname>Zend_Http_Client</classname> provides an easy interface for preforming Hyper-Text
-        Transfer Protocol (HTTP) requests. <classname>Zend_Http_Client</classname> supports most simple
-        features expected from an <acronym>HTTP</acronym> client, as well as some more complex
-        features such as <acronym>HTTP</acronym> authentication and file uploads. Successful
+        Transfer Protocol (HTTP) requests. <classname>Zend_Http_Client</classname> supports most
+        simple features expected from an <acronym>HTTP</acronym> client, as well as some more
+        complex features such as <acronym>HTTP</acronym> authentication and file uploads. Successful
         requests (and most unsuccessful ones too) return a <classname>Zend_Http_Response</classname>
         object, which provides access to the response's headers and body (see
         <xref linkend="zend.http.response" />).
     </para>
+
     <sect2 id="zend.http.client.usage">
         <title>Using Zend_Http_Client</title>
+
         <para>
             The class constructor optionally accepts a URL as its first parameter
             (can be either a string or a Zend_Uri_Http object), and an array or
             Zend_Config object containing configuration options. Both can be left out,
             and set later using the setUri() and setConfig() methods.
+
             <example id="zend.http.client.introduction.example-1">
                 <title>Instantiating a Zend_Http_Client Object</title>
+
                 <programlisting language="php"><![CDATA[
 $client = new Zend_Http_Client('http://example.org', array(
     'maxredirects' => 0,
@@ -53,12 +58,15 @@ $client->setConfig($config);
 
     <sect2 id="zend.http.client.configuration">
         <title>Configuration Parameters</title>
+
         <para>
             The constructor and setConfig() method accept an associative array
-            of configuration parameters, or a <classname>Zend_Config</classname> object. Setting these
-            parameters is optional, as they all have default values.
+            of configuration parameters, or a <classname>Zend_Config</classname> object. Setting
+            these parameters is optional, as they all have default values.
+
             <table id="zend.http.client.configuration.table">
                 <title>Zend_Http_Client configuration parameters</title>
+
                 <tgroup cols="4">
                     <thead>
                         <row>
@@ -68,6 +76,7 @@ $client->setConfig($config);
                             <entry>Default Value</entry>
                         </row>
                     </thead>
+
                     <tbody>
                         <row>
                             <entry>maxredirects</entry>
@@ -75,6 +84,7 @@ $client->setConfig($config);
                             <entry>integer</entry>
                             <entry>5</entry>
                         </row>
+
                         <row>
                             <entry>strict</entry>
 
@@ -87,43 +97,65 @@ $client->setConfig($config);
                             <entry>boolean</entry>
                             <entry><constant>TRUE</constant></entry>
                         </row>
+
                         <row>
                             <entry>strictredirects</entry>
-                            <entry>Whether to strictly follow the <acronym>RFC</acronym> when redirecting (see <xref linkend="zend.http.client.redirections" />)</entry>
+
+                            <entry>
+                                Whether to strictly follow the <acronym>RFC</acronym> when
+                                redirecting (see <xref linkend="zend.http.client.redirections" />)
+                            </entry>
+
                             <entry>boolean</entry>
                             <entry><constant>FALSE</constant></entry>
                         </row>
+
                         <row>
                             <entry>useragent</entry>
                             <entry>User agent identifier string (sent in request headers)</entry>
                             <entry>string</entry>
                             <entry>'Zend_Http_Client'</entry>
                         </row>
+
                         <row>
                             <entry>timeout</entry>
                             <entry>Connection timeout (seconds)</entry>
                             <entry>integer</entry>
                             <entry>10</entry>
                         </row>
+
                         <row>
                             <entry>httpversion</entry>
                             <entry>HTTP protocol version (usually '1.1' or '1.0')</entry>
                             <entry>string</entry>
                             <entry>'1.1'</entry>
                         </row>
+
                         <row>
                             <entry>adapter</entry>
-                            <entry>Connection adapter class to use (see <xref linkend="zend.http.client.adapters" />)</entry>
+
+                            <entry>
+                                Connection adapter class to use (see <xref
+                                    linkend="zend.http.client.adapters" />)
+                            </entry>
+
                             <entry>mixed</entry>
                             <entry>'Zend_Http_Client_Adapter_Socket'</entry>
                         </row>
+
                         <row>
                             <entry>keepalive</entry>
-                            <entry>Whether to enable keep-alive connections with the server. Useful and might improve performance if several
-                            consecutive requests to the same server are performed.</entry>
+
+                            <entry>
+                                Whether to enable keep-alive connections with the server. Useful and
+                                might improve performance if several consecutive requests to the
+                                same server are performed.
+                            </entry>
+
                             <entry>boolean</entry>
                             <entry><constant>FALSE</constant></entry>
                         </row>
+
                         <row>
                             <entry>storeresponse</entry>
 
@@ -143,35 +175,45 @@ $client->setConfig($config);
             </table>
         </para>
     </sect2>
+
     <sect2 id="zend.http.client.basic-requests">
         <title>Performing Basic HTTP Requests</title>
+
         <para>
             Performing simple HTTP requests is very easily done using the
             request() method, and rarely needs more than three lines of code:
+
             <example id="zend.http.client.basic-requests.example-1">
                 <title>Performing a Simple GET Request</title>
+
                 <programlisting language="php"><![CDATA[
 $client = new Zend_Http_Client('http://example.org');
 $response = $client->request();
 ]]></programlisting>
             </example>
+
             The request() method takes one optional parameter - the request method.
             This can be either GET, POST, PUT, HEAD, DELETE, TRACE, OPTIONS or
             CONNECT as defined by the HTTP protocol
+
             <footnote>
               <para>
                 See RFC 2616 - <ulink url="http://www.w3.org/Protocols/rfc2616/rfc2616.html" />.
               </para>
             </footnote>.
+
             For convenience, these are all defined as class constants:
             Zend_Http_Client::GET, Zend_Http_Client::POST and so on.
         </para>
+
         <para>
             If no method is specified, the method set by the last setMethod()
             call is used. If setMethod() was never called, the default request
             method is GET (see the above example).
+
             <example id="zend.http.client.basic-requests.example-2">
                 <title>Using Request Methods Other Than GET</title>
+
                 <programlisting language="php"><![CDATA[
 // Preforming a POST request
 $response = $client->request('POST');
@@ -186,6 +228,7 @@ $response = $client->request();
 
     <sect2 id="zend.http.client.parameters">
         <title>Adding GET and POST parameters </title>
+
         <para>
             Adding GET parameters to an HTTP request is quite simple, and can
             be done either by specifying them as part of the URL, or by using
@@ -195,8 +238,10 @@ $response = $client->request();
             For convenience, the setParameterGet() method can also accept a
             single associative array of name => value GET variables - which may
             be more comfortable when several GET parameters need to be set.
+
             <example id="zend.http.client.parameters.example-1">
                 <title>Setting GET Parameters</title>
+
                 <programlisting language="php"><![CDATA[
 // Setting a get parameter using the setParameterGet method
 $client->setParameterGet('knight', 'lancelot');
@@ -213,14 +258,17 @@ $client->setParameterGet(array(
 ]]></programlisting>
             </example>
         </para>
+
         <para>
             While GET parameters can be sent with every request method, POST
             parameters are only sent in the body of POST requests. Adding POST
             parameters to a request is very similar to adding GET parameters,
             and can be done with the setParameterPost() method, which is
             similar to the setParameterGet() method in structure.
+
             <example id="zend.http.client.parameters.example-2">
                 <title>Setting POST Parameters</title>
+
                 <programlisting language="php"><![CDATA[
 // Setting a POST parameter
 $client->setParameterPost('language', 'fr');
@@ -233,6 +281,7 @@ $client->setParameterPost(array(
 ));
 ]]></programlisting>
             </example>
+
             Note that when sending POST requests, you can set both GET and
             POST parameters. On the other hand, while setting POST parameters
             for a non-POST request will not trigger and error, it is useless.
@@ -243,6 +292,7 @@ $client->setParameterPost(array(
 
     <sect2 id="zend.http.client.accessing_last">
         <title>Accessing Last Request and Response</title>
+
         <para>
             <classname>Zend_Http_Client</classname> provides methods of accessing the last request
             sent and last response received by the client object.
@@ -253,9 +303,7 @@ $client->setParameterPost(array(
             <link linkend="zend.http.response">Zend_Http_Response</link> object.
         </para>
     </sect2>
-
 </sect1>
-
 <!--
 vim:se ts=4 sw=4 et:
 -->

+ 203 - 134
documentation/manual/en/module_specs/Zend_Http_Cookie-Handling.xml

@@ -5,53 +5,65 @@
 
     <sect2 id="zend.http.cookies.introduction">
         <title>Introduction</title>
+
         <para>
-            <classname>Zend_Http_Cookie</classname>, as expected, is a class that represents an <acronym>HTTP</acronym>
-            cookie. It provides methods for parsing <acronym>HTTP</acronym> response strings,
-            collecting cookies, and easily accessing their properties. It also
+            <classname>Zend_Http_Cookie</classname>, as expected, is a class that represents an
+            <acronym>HTTP</acronym> cookie. It provides methods for parsing <acronym>HTTP</acronym>
+            response strings, collecting cookies, and easily accessing their properties. It also
             allows checking if a cookie matches against a specific scenario, IE
             a request <acronym>URL</acronym>, expiration time, secure connection, etc.
         </para>
+
         <para>
-            <classname>Zend_Http_CookieJar</classname> is an object usually used by <classname>Zend_Http_Client</classname> to
-            hold a set of <classname>Zend_Http_Cookie</classname> objects. The idea is that if a
-            <classname>Zend_Http_CookieJar</classname> object is attached to a <classname>Zend_Http_Client</classname> object,
-            all cookies going from and into the client through <acronym>HTTP</acronym> requests and
-            responses will be stored by the CookieJar object. Then, when the client
-            will send another request, it will first ask the CookieJar object for
-            all cookies matching the request. These will be added to the request
-            headers automatically. This is highly useful in cases where you need to
+            <classname>Zend_Http_CookieJar</classname> is an object usually used by
+            <classname>Zend_Http_Client</classname> to hold a set of
+            <classname>Zend_Http_Cookie</classname> objects. The idea is that if a
+            <classname>Zend_Http_CookieJar</classname> object is attached to a
+            <classname>Zend_Http_Client</classname> object, all cookies going from and into the
+            client through <acronym>HTTP</acronym> requests and responses will be stored by the
+            CookieJar object. Then, when the client will send another request, it will first ask the
+            CookieJar object for all cookies matching the request. These will be added to the
+            request headers automatically. This is highly useful in cases where you need to
             maintain a user session over consecutive <acronym>HTTP</acronym> requests, automatically
             sending the session ID cookies when required. Additionally, the
-            <classname>Zend_Http_CookieJar</classname> object can be serialized and stored in $_SESSION
-            when needed.
+            <classname>Zend_Http_CookieJar</classname> object can be serialized and stored in
+            $_SESSION when needed.
         </para>
     </sect2>
 
     <sect2 id="zend.http.cookies.cookie.instantiating">
         <title>Instantiating Zend_Http_Cookie Objects</title>
+
         <para>
             Instantiating a Cookie object can be done in two ways:
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    Through the constructor, using the following syntax:
-                    <code>new <classname>Zend_Http_Cookie</classname>(string $name, string $value, string $domain, [int $expires, [string $path, [boolean $secure]]]);</code>
+                        Through the constructor, using the following syntax:
+                        <code>new <classname>Zend_Http_Cookie</classname>(string $name, string
+                            $value, string $domain, [int $expires, [string $path, [boolean
+                            $secure]]]);</code>
                     </para>
+
                     <itemizedlist>
                         <listitem>
                             <para>
-                            <varname>$name</varname>: The name of the cookie (eg. 'PHPSESSID') (required)
+                                <varname>$name</varname>: The name of the cookie (eg. 'PHPSESSID')
+                                (required)
                             </para>
                         </listitem>
+
                         <listitem>
                             <para>
-                            <varname>$value</varname>: The value of the cookie (required)
+                                <varname>$value</varname>: The value of the cookie (required)
                             </para>
                         </listitem>
+
                         <listitem>
                             <para>
-                            <varname>$domain</varname>: The cookie's domain (eg. '.example.com') (required)
+                                <varname>$domain</varname>: The cookie's domain (eg. '.example.com')
+                                (required)
                             </para>
                         </listitem>
 
@@ -66,7 +78,8 @@
 
                         <listitem>
                             <para>
-                            <varname>$path</varname>: Cookie path, eg. '/foo/bar/' (optional, defaults to '/')
+                                <varname>$path</varname>: Cookie path, eg. '/foo/bar/' (optional,
+                                defaults to '/')
                             </para>
                         </listitem>
 
@@ -79,18 +92,22 @@
                         </listitem>
                     </itemizedlist>
                 </listitem>
+
                 <listitem>
                     <para>
-                    By calling the fromString() static method, with a cookie string as represented in the
-                    'Set-Cookie' <acronym>HTTP</acronym> response header or 'Cookie' <acronym>HTTP</acronym> request header. In this case, the
-                    cookie value must already be encoded. When the cookie string does not contain a 'domain'
-                    part, you must provide a reference <acronym>URI</acronym> according to which the cookie's domain and path
-                    will be set.
+                        By calling the fromString() static method, with a cookie string as
+                        represented in the 'Set-Cookie' <acronym>HTTP</acronym> response header or
+                        'Cookie' <acronym>HTTP</acronym> request header. In this case, the cookie
+                        value must already be encoded. When the cookie string does not contain a
+                        'domain' part, you must provide a reference <acronym>URI</acronym> according
+                        to which the cookie's domain and path will be set.
                     </para>
                 </listitem>
             </itemizedlist>
+
             <example id="zend.http.cookies.cookie.instantiating.example-1">
                <title>Instantiating a Zend_Http_Cookie object</title>
+
                <programlisting language="php"><![CDATA[
 // First, using the constructor. This cookie will expire in 2 hours
 $cookie = new Zend_Http_Cookie('foo',
@@ -110,21 +127,26 @@ $cookie = Zend_Http_Cookie::fromString('foo=bar; secure;',
                                        'http://www.example.com/path');
 ]]></programlisting>
             </example>
+
             <note>
                 <para>
-                When instantiating a cookie object using the <classname>Zend_Http_Cookie</classname>::fromString() method, the
-                cookie value is expected to be <acronym>URL</acronym> encoded, as cookie strings should be. However, when
-                using the constructor, the cookie value string is expected to be the real, decoded value.
+                    When instantiating a cookie object using the
+                    <classname>Zend_Http_Cookie</classname>::fromString() method, the cookie value
+                    is expected to be <acronym>URL</acronym> encoded, as cookie strings should be.
+                    However, when using the constructor, the cookie value string is expected to be
+                    the real, decoded value.
                 </para>
             </note>
         </para>
+
         <para>
-            A cookie object can be transferred back into a string, using the __toString() magic method.
-            This method will produce a HTTP request "Cookie" header string, showing the cookie's name
-            and value, and terminated by a semicolon (';').
+            A cookie object can be transferred back into a string, using the __toString() magic
+            method. This method will produce a HTTP request "Cookie" header string, showing the
+            cookie's name and value, and terminated by a semicolon (';').
             The value will be URL encoded, as expected in a Cookie header:
             <example id="zend.http.cookies.cookie.instantiating.example-2">
                <title>Stringifying a Zend_Http_Cookie object</title>
+
                <programlisting language="php"><![CDATA[
 // Create a new cookie
 $cookie = new Zend_Http_Cookie('foo',
@@ -148,28 +170,34 @@ echo $cookie;
 
     <sect2 id="zend.http.cookies.cookie.accessors">
         <title>Zend_Http_Cookie getter methods</title>
+
         <para>
-            Once a <classname>Zend_Http_Cookie</classname> object is instantiated, it provides several getter methods to get
-            the different properties of the <acronym>HTTP</acronym> cookie:
+            Once a <classname>Zend_Http_Cookie</classname> object is instantiated, it provides
+            several getter methods to get the different properties of the <acronym>HTTP</acronym>
+            cookie:
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    <code>string getName()</code>: Get the name of the cookie
+                        <code>string getName()</code>: Get the name of the cookie
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <code>string getValue()</code>: Get the real, decoded value of the cookie
+                        <code>string getValue()</code>: Get the real, decoded value of the cookie
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <code>string getDomain()</code>: Get the cookie's domain
+                        <code>string getDomain()</code>: Get the cookie's domain
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <code>string getPath()</code>: Get the cookie's path, which defaults to '/'
+                        <code>string getPath()</code>: Get the cookie's path, which defaults to '/'
                     </para>
                 </listitem>
 
@@ -182,8 +210,10 @@ echo $cookie;
                 </listitem>
             </itemizedlist>
         </para>
+
         <para>
             Additionally, several boolean tester methods are provided:
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -202,17 +232,21 @@ echo $cookie;
                         current time stamp as the time to check the cookie against.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <code>boolean isSessionCookie()</code>: Check whether the cookie is a "session cookie" - that
-                    is a cookie with no expiration time, which is meant to expire when the session ends.
+                        <code>boolean isSessionCookie()</code>: Check whether the cookie is a
+                        "session cookie" - that is a cookie with no expiration time, which is meant
+                        to expire when the session ends.
                     </para>
                 </listitem>
             </itemizedlist>
         </para>
+
         <para>
             <example id="zend.http.cookies.cookie.accessors.example-1">
                 <title>Using getter methods with Zend_Http_Cookie</title>
+
                 <programlisting language="php"><![CDATA[
 // First, create the cookie
 $cookie =
@@ -245,18 +279,23 @@ echo ($cookie->isSessionCookie() ? 'Yes' : 'No');
 
     <sect2 id="zend.http.cookies.cookie.matching">
         <title>Zend_Http_Cookie: Matching against a scenario</title>
+
         <para>
-            The only real logic contained in a <classname>Zend_Http_Cookie</classname> object, is in the match() method.
-            This method is used to test a cookie against a given <acronym>HTTP</acronym> request scenario, in order
-            to tell whether the cookie should be sent in this request or not. The method has
-            the following syntax and parameters:
-            <code>boolean Zend_Http_Cookie->match(mixed $uri, [boolean $matchSessionCookies, [int $now]]);</code>
+            The only real logic contained in a <classname>Zend_Http_Cookie</classname> object, is in
+            the match() method. This method is used to test a cookie against a given
+            <acronym>HTTP</acronym> request scenario, in order to tell whether the cookie should be
+            sent in this request or not. The method has the following syntax and parameters:
+            <code>boolean Zend_Http_Cookie->match(mixed $uri, [boolean $matchSessionCookies, [int
+                $now]]);</code>
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    <code>mixed $uri</code>: A <classname>Zend_Uri_Http</classname> object with a domain name and path to be checked.
-                    Optionally, a string representing a valid <acronym>HTTP</acronym> <acronym>URL</acronym> can be passed instead. The cookie will
-                    match if the <acronym>URL</acronym>'s scheme (HTTP or <acronym>HTTPS</acronym>), domain and path all match.
+                        <code>mixed $uri</code>: A <classname>Zend_Uri_Http</classname> object with
+                        a domain name and path to be checked. Optionally, a string representing a
+                        valid <acronym>HTTP</acronym> <acronym>URL</acronym> can be passed instead.
+                        The cookie will match if the <acronym>URL</acronym>'s scheme (HTTP or
+                        <acronym>HTTPS</acronym>), domain and path all match.
                     </para>
                 </listitem>
 
@@ -271,13 +310,16 @@ echo ($cookie->isSessionCookie() ? 'Yes' : 'No');
 
                 <listitem>
                     <para>
-                    <code>int $now</code>: Time (represented as UNIX time stamp) to check a cookie against
-                    for expiration. If not specified, will default to the current time.
+                        <code>int $now</code>: Time (represented as UNIX time stamp) to check a
+                        cookie against for expiration. If not specified, will default to the current
+                        time.
                     </para>
                 </listitem>
             </itemizedlist>
+
             <example id="zend.http.cookies.cookie.matching.example-1">
                 <title>Matching cookies</title>
+
                 <programlisting language="php"><![CDATA[
 // Create the cookie object - first, a secure session cookie
 $cookie = Zend_Http_Cookie::fromString('foo=two+words; ' +
@@ -330,53 +372,62 @@ $cookie->match('http://www.example.com/', true, time() + (3 * 3600));
 
     <sect2 id="zend.http.cookies.cookiejar">
         <title>The Zend_Http_CookieJar Class: Instantiation</title>
+
         <para>
             In most cases, there is no need to directly instantiate a
-            <classname>Zend_Http_CookieJar</classname> object. If you want to attach a new cookie jar
-            to your <classname>Zend_Http_Client</classname> object, just call the
+            <classname>Zend_Http_CookieJar</classname> object. If you want to attach a new cookie
+            jar to your <classname>Zend_Http_Client</classname> object, just call the
             Zend_Http_Client->setCookieJar() method, and a new, empty cookie jar
             will be attached to your client. You could later get this cookie jar
             using Zend_Http_Client->getCookieJar().
         </para>
+
         <para>
             If you still wish to manually instantiate a CookieJar object, you
             can do so by calling "new Zend_Http_CookieJar()" directly - the
             constructor method does not take any parameters. Another way to
             instantiate a CookieJar object is to use the static Zend_Http_CookieJar::fromResponse()
-            method. This method takes two parameters: a <classname>Zend_Http_Response</classname> object,
-            and a reference <acronym>URI</acronym>, as either a string or a <classname>Zend_Uri_Http</classname> object.
-            This method will return a new <classname>Zend_Http_CookieJar</classname> object, already
-            containing the cookies set by the passed <acronym>HTTP</acronym> response. The reference
-            <acronym>URI</acronym> will be used to set the cookie's domain and path, if they are
-            not defined in the Set-Cookie headers.
+            method. This method takes two parameters: a <classname>Zend_Http_Response</classname>
+            object, and a reference <acronym>URI</acronym>, as either a string or a
+            <classname>Zend_Uri_Http</classname> object. This method will return a new
+            <classname>Zend_Http_CookieJar</classname> object, already containing the cookies set by
+            the passed <acronym>HTTP</acronym> response. The reference <acronym>URI</acronym> will
+            be used to set the cookie's domain and path, if they are not defined in the Set-Cookie
+            headers.
         </para>
     </sect2>
 
     <sect2 id="zend.http.cookies.cookiejar.adding_cookies">
         <title>Adding Cookies to a Zend_Http_CookieJar object</title>
+
         <para>
-            Usually, the <classname>Zend_Http_Client</classname> object you attached your CookieJar object
-            to will automatically add cookies set by <acronym>HTTP</acronym> responses to your jar. If
-            you wish to manually add cookies to your jar, this can be done by using
+            Usually, the <classname>Zend_Http_Client</classname> object you attached your CookieJar
+            object to will automatically add cookies set by <acronym>HTTP</acronym> responses to
+            your jar. if you wish to manually add cookies to your jar, this can be done by using
             two methods:
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    <classname>Zend_Http_CookieJar->addCookie($cookie[, $ref_uri])</classname>: Add a
-                    single cookie to the jar. $cookie can be either a <classname>Zend_Http_Cookie</classname>
-                    object or a string, which will be converted automatically into a
-                    Cookie object. If a string is provided, you should also provide
-                    $ref_uri - which is a reference <acronym>URI</acronym> either as a string or
-                    <classname>Zend_Uri_Http</classname> object, to use as the cookie's default domain and path.
+                        <classname>Zend_Http_CookieJar->addCookie($cookie[, $ref_uri])</classname>:
+                        Add a single cookie to the jar. $cookie can be either a
+                        <classname>Zend_Http_Cookie</classname> object or a string, which will be
+                        converted automatically into a Cookie object. If a string is provided, you
+                        should also provide $ref_uri - which is a reference <acronym>URI</acronym>
+                        either as a string or <classname>Zend_Uri_Http</classname> object, to use as
+                        the cookie's default domain and path.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <classname>Zend_Http_CookieJar->addCookiesFromResponse($response, $ref_uri)</classname>:
-                    Add all cookies set in a single <acronym>HTTP</acronym> response to the jar. $response is
-                    expected to be a <classname>Zend_Http_Response</classname> object with Set-Cookie headers. $ref_uri
-                    is the request <acronym>URI</acronym>, either as a string or a <classname>Zend_Uri_Http</classname> object, according
-                    to which the cookies' default domain and path will be set.
+                        <classname>Zend_Http_CookieJar->addCookiesFromResponse($response,
+                            $ref_uri)</classname>: Add all cookies set in a single
+                        <acronym>HTTP</acronym> response to the jar. $response is expected to be a
+                        <classname>Zend_Http_Response</classname> object with Set-Cookie headers.
+                        $ref_uri is the request <acronym>URI</acronym>, either as a string or a
+                        <classname>Zend_Uri_Http</classname> object, according to which the cookies'
+                        default domain and path will be set.
                     </para>
                 </listitem>
             </itemizedlist>
@@ -385,111 +436,129 @@ $cookie->match('http://www.example.com/', true, time() + (3 * 3600));
 
     <sect2 id="zend.http.cookies.cookiejar.getting_cookies">
         <title>Retrieving Cookies From a Zend_Http_CookieJar object</title>
+
         <para>
             Just like with adding cookies, there is usually no need to manually
-            fetch cookies from a CookieJar object. Your <classname>Zend_Http_Client</classname> object
-            will automatically fetch the cookies required for an <acronym>HTTP</acronym> request
-            for you. However, you can still use 3 provided methods to fetch
+            fetch cookies from a CookieJar object. Your <classname>Zend_Http_Client</classname>
+            object will automatically fetch the cookies required for an <acronym>HTTP</acronym>
+            request for you. However, you can still use 3 provided methods to fetch
             cookies from the jar object: <methodname>getCookie()</methodname>,
-            <methodname>getAllCookies()</methodname>, and <methodname>getMatchingCookies()</methodname>.
-            Additionnaly, iterating over the CookieJar will let you
-            retrieve all the <classname>Zend_Http_Cookie</classname> objects from it.
+            <methodname>getAllCookies()</methodname>, and
+            <methodname>getMatchingCookies()</methodname>. Additionnaly, iterating over the
+            CookieJar will let you retrieve all the <classname>Zend_Http_Cookie</classname> objects
+            from it.
         </para>
+
         <para>
             It is important to note that each one of these methods takes a
             special parameter, which sets the return type of the method. This
             parameter can have 3 values:
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    <constant>Zend_Http_CookieJar::COOKIE_OBJECT</constant>: Return
-                    a <classname>Zend_Http_Cookie</classname> object. If the method returns more than
-                    one cookie, an array of objects will be returned.
+                        <constant>Zend_Http_CookieJar::COOKIE_OBJECT</constant>: Return
+                        a <classname>Zend_Http_Cookie</classname> object. If the method returns more
+                        than one cookie, an array of objects will be returned.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <constant>Zend_Http_CookieJar::COOKIE_STRING_ARRAY</constant>: Return
-                    cookies as strings, in a "foo=bar" format, suitable for sending
-                    in a <acronym>HTTP</acronym> request "Cookie" header. If more than one cookie is
-                    returned, an array of strings is returned.
+                        <constant>Zend_Http_CookieJar::COOKIE_STRING_ARRAY</constant>: Return
+                        cookies as strings, in a "foo=bar" format, suitable for sending
+                        in a <acronym>HTTP</acronym> request "Cookie" header. If more than one
+                        cookie is returned, an array of strings is returned.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <constant>Zend_Http_CookieJar::COOKIE_STRING_CONCAT</constant>: Similar to
-                    COOKIE_STRING_ARRAY, but if more than one cookie is returned, this
-                    method will concatenate all cookies into a single, long string
-                    separated by semicolons (;), and return it. This is especially useful
-                    if you want to directly send all matching cookies in a single <acronym>HTTP</acronym>
-                    request "Cookie" header.
+                        <constant>Zend_Http_CookieJar::COOKIE_STRING_CONCAT</constant>: Similar to
+                        COOKIE_STRING_ARRAY, but if more than one cookie is returned, this
+                        method will concatenate all cookies into a single, long string
+                        separated by semicolons (;), and return it. This is especially useful
+                        if you want to directly send all matching cookies in a single
+                        <acronym>HTTP</acronym> request "Cookie" header.
                     </para>
                 </listitem>
             </itemizedlist>
         </para>
+
         <para>
             The structure of the different cookie-fetching methods is described below:
+
             <itemizedlist>
                 <listitem>
                     <para>
-                    <classname>Zend_Http_CookieJar->getCookie($uri, $cookie_name[, $ret_as])</classname>:
-                    Get a single cookie from the jar, according to its <acronym>URI</acronym> (domain and path)
-                    and name. $uri is either a string or a <classname>Zend_Uri_Http</classname> object representing the
-                    <acronym>URI</acronym>. $cookie_name is a string identifying the cookie name. $ret_as
-                    specifies the return type as described above. $ret_type is optional, and
-                    defaults to COOKIE_OBJECT.
+                        <classname>Zend_Http_CookieJar->getCookie($uri, $cookie_name[,
+                            $ret_as])</classname>: Get a single cookie from the jar, according to
+                        its <acronym>URI</acronym> (domain and path) and name. $uri is either a
+                        string or a <classname>Zend_Uri_Http</classname> object representing the
+                        <acronym>URI</acronym>. $cookie_name is a string identifying the cookie
+                        name. $ret_as specifies the return type as described above. $ret_type is
+                        optional, and defaults to COOKIE_OBJECT.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <classname>Zend_Http_CookieJar->getAllCookies($ret_as)</classname>: Get all
-                    cookies from the jar. $ret_as specifies the return type as described
-                    above. If not specified, $ret_type defaults to COOKIE_OBJECT.
+                        <classname>Zend_Http_CookieJar->getAllCookies($ret_as)</classname>: Get all
+                        cookies from the jar. $ret_as specifies the return type as described
+                        above. If not specified, $ret_type defaults to COOKIE_OBJECT.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                    <classname>Zend_Http_CookieJar->getMatchingCookies($uri[, $matchSessionCookies[, $ret_as[, $now]]])</classname>:
-                    Get all cookies from the jar that match a specified scenario, that is a <acronym>URI</acronym> and expiration time.
-                    <itemizedlist>
-                        <listitem>
-                            <para>
-                            <varname>$uri</varname> is either a <classname>Zend_Uri_Http</classname> object or a string specifying the
-                            connection type (secure or non-secure), domain and path to match against.
-                            </para>
-                        </listitem>
-
-                        <listitem>
-                            <para>
-                                <varname>$matchSessionCookies</varname> is a boolean telling whether
-                                to match session cookies or not. Session cookies are cookies that
-                                have no specified expiration time. Defaults to
-                                <constant>TRUE</constant>.
-                            </para>
-                        </listitem>
-
-                        <listitem>
-                            <para>
-                            <varname>$ret_as</varname> specifies the return type as described above. If not
-                            specified, defaults to COOKIE_OBJECT.
-                            </para>
-                        </listitem>
-                        <listitem>
-                            <para>
-                            <varname>$now</varname> is an integer representing the UNIX time stamp to consider
-                            as "now" - that is any cookies who are set to expire before this time will
-                            not be matched. If not specified, defaults to the current time.
-                            </para>
-                        </listitem>
-                    </itemizedlist>
-                    You can read more about cookie matching here:
-                    <xref linkend="zend.http.cookies.cookie.matching" />.
+                        <classname>Zend_Http_CookieJar->getMatchingCookies($uri[,
+                            $matchSessionCookies[, $ret_as[, $now]]])</classname>: Get all cookies
+                        from the jar that match a specified scenario, that is a
+                        <acronym>URI</acronym> and expiration time.
+
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    <varname>$uri</varname> is either a
+                                    <classname>Zend_Uri_Http</classname> object or a string
+                                    specifying the connection type (secure or non-secure), domain
+                                    and path to match against.
+                                </para>
+                            </listitem>
+
+                            <listitem>
+                                <para>
+                                    <varname>$matchSessionCookies</varname> is a boolean telling
+                                    whether to match session cookies or not. Session cookies are
+                                    cookies that have no specified expiration time. Defaults to
+                                    <constant>TRUE</constant>.
+                                </para>
+                            </listitem>
+
+                            <listitem>
+                                <para>
+                                    <varname>$ret_as</varname> specifies the return type as
+                                    described above. If not specified, defaults to COOKIE_OBJECT.
+                                </para>
+                            </listitem>
+
+                            <listitem>
+                                <para>
+                                    <varname>$now</varname> is an integer representing the UNIX time
+                                    stamp to consider as "now" - that is any cookies who are set to
+                                    expire before this time will not be matched. If not specified,
+                                    defaults to the current time.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
+
+                        You can read more about cookie matching here:
+                        <xref linkend="zend.http.cookies.cookie.matching" />.
                     </para>
                 </listitem>
             </itemizedlist>
         </para>
     </sect2>
-
 </sect1>
 <!--
 vim:se ts=4 sw=4 et:

+ 91 - 38
documentation/manual/en/module_specs/Zend_Http_Response.xml

@@ -5,18 +5,22 @@
 
     <sect2 id="zend.http.response.introduction">
         <title>Introduction</title>
+
         <para>
-            <classname>Zend_Http_Response</classname> provides easy access to an <acronym>HTTP</acronym> responses
-            message, as well as a set of static methods for parsing <acronym>HTTP</acronym>
-            response messages. Usually, <classname>Zend_Http_Response</classname> is used as an object
-            returned by a <classname>Zend_Http_Client</classname> request.
+            <classname>Zend_Http_Response</classname> provides easy access to an
+            <acronym>HTTP</acronym> responses message, as well as a set of static methods for
+            parsing <acronym>HTTP</acronym> response messages. Usually,
+            <classname>Zend_Http_Response</classname> is used as an object returned by a
+            <classname>Zend_Http_Client</classname> request.
         </para>
+
         <para>
             In most cases, a Zend_Http_Response object will be instantiated
             using the fromString() method, which reads a string containing an HTTP
             response message, and returns a new Zend_Http_Response object:
             <example id="zend.http.response.introduction.example-1">
                 <title>Instantiating a Zend_Http_Response Object Using the Factory Method</title>
+
                 <programlisting language="php"><![CDATA[
 $str = '';
 $sock = fsockopen('www.example.com', 80);
@@ -33,46 +37,58 @@ $response = Zend_Http_Response::fromString($str);
 ]]></programlisting>
             </example>
         </para>
+
         <para>
             You can also use the contractor method to create a new response
             object, by specifying all the parameters of the response:
         </para>
+
         <para>
-            <code>
-                public function __construct($code, $headers, $body = null, $version = '1.1', $message = null)
-            </code>
+            <code>public function __construct($code, $headers, $body = null, $version = '1.1',
+                $message = null)</code>
         </para>
+
         <itemizedlist>
             <listitem>
                 <para>
-                    <varname>$code</varname>: The <acronym>HTTP</acronym> response code (eg. 200, 404, etc.)
+                    <varname>$code</varname>: The <acronym>HTTP</acronym> response code (eg. 200,
+                    404, etc.)
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <varname>$headers</varname>: An associative array of <acronym>HTTP</acronym> response headers (eg. 'Host' => 'example.com')
+                    <varname>$headers</varname>: An associative array of <acronym>HTTP</acronym>
+                    response headers (eg. 'Host' => 'example.com')
                 </para>
             </listitem>
+
             <listitem>
                 <para>
                     <varname>$body</varname>: The response body as a string
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <varname>$version</varname>: The <acronym>HTTP</acronym> response version (usually 1.0 or 1.1)
+                    <varname>$version</varname>: The <acronym>HTTP</acronym> response version
+                    (usually 1.0 or 1.1)
                 </para>
             </listitem>
+
             <listitem>
                 <para>
-                    <varname>$message</varname>: The <acronym>HTTP</acronym> response message (eg 'OK', 'Internal Server Error').
-                    If not specified, the message will be set according to the response code
+                    <varname>$message</varname>: The <acronym>HTTP</acronym> response message (eg
+                    'OK', 'Internal Server Error'). If not specified, the message will be set
+                    according to the response code
                 </para>
             </listitem>
         </itemizedlist>
     </sect2>
+
     <sect2 id="zend.http.response.testers">
         <title>Boolean Tester Methods</title>
+
         <para>
             Once a <classname>Zend_Http_Response</classname> object is instantiated, it provides
             several methods that can be used to test the type of the response. These all
@@ -85,6 +101,7 @@ $response = Zend_Http_Response::fromString($str);
                         2xx response codes
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>Boolean isError()</code>: Whether the response code implies an error
@@ -92,6 +109,7 @@ $response = Zend_Http_Response::fromString($str);
                         (client errors) and 5xx (server errors) response codes
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>Boolean isRedirect()</code>: Whether the response is a redirection
@@ -100,8 +118,10 @@ $response = Zend_Http_Response::fromString($str);
                     </para>
                 </listitem>
             </itemizedlist>
+
             <example id="zend.http.response.testers.example-1">
                 <title>Using the isError() method to validate a response</title>
+
                 <programlisting language="php"><![CDATA[
 if ($response->isError()) {
   echo "Error transmitting data.\n"
@@ -113,46 +133,57 @@ if ($response->isError()) {
             </example>
         </para>
     </sect2>
+
     <sect2 id="zend.http.response.acessors">
         <title>Accessor Methods</title>
+
         <para>
             The main goal of the response object is to provide easy access to
             various response parameters.
             <itemizedlist>
                 <listitem>
                     <para>
-                        <code>int getStatus()</code>: Get the <acronym>HTTP</acronym> response status code (eg. 200, 504, etc.)
+                        <code>int getStatus()</code>: Get the <acronym>HTTP</acronym> response
+                        status code (eg. 200, 504, etc.)
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string getMessage()</code>: Get the <acronym>HTTP</acronym> response status message (eg. "Not Found",
-                        "Authorization Required")
+                        <code>string getMessage()</code>: Get the <acronym>HTTP</acronym> response
+                        status message (eg. "Not Found", "Authorization Required")
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string getBody()</code>: Get the fully decoded <acronym>HTTP</acronym> response body
+                        <code>string getBody()</code>: Get the fully decoded <acronym>HTTP</acronym>
+                        response body
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string getRawBody()</code>: Get the raw, possibly encoded <acronym>HTTP</acronym> response body. If
-                        the body was decoded using GZIP encoding for example, it will not be decoded.
+                        <code>string getRawBody()</code>: Get the raw, possibly encoded
+                        <acronym>HTTP</acronym> response body. if the body was decoded using GZIP
+                        encoding for example, it will not be decoded.
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>array getHeaders()</code>: Get the <acronym>HTTP</acronym> response headers as an associative array
-                        (eg. 'Content-type' => 'text/html')
+                        <code>array getHeaders()</code>: Get the <acronym>HTTP</acronym> response
+                        headers as an associative array (eg. 'Content-type' => 'text/html')
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string|array getHeader($header)</code>: Get a specific <acronym>HTTP</acronym> response header, specified
-                        by $header
+                        <code>string|array getHeader($header)</code>: Get a specific
+                        <acronym>HTTP</acronym> response header, specified by $header
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>string getHeadersAsString($status_line = true, $br = "\n")</code>: Get
@@ -162,17 +193,20 @@ if ($response->isError()) {
                         be, for example, "&lt;br /&gt;")
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string asString($br = "\n")</code>: Get the entire response message as a string.
-                        Lines are broken with the $br parameter (Can be, for example, "&lt;br /&gt;").
-                        You can also use the magic method __toString() when casting the object as a string. It will
-                        then proxy to asString()
+                        <code>string asString($br = "\n")</code>: Get the entire response message as
+                        a string. Lines are broken with the $br parameter (Can be, for example,
+                        "&lt;br /&gt;"). You can also use the magic method __toString() when casting
+                        the object as a string. It will then proxy to asString()
                     </para>
                 </listitem>
             </itemizedlist>
+
             <example id="zend.http.response.acessors.example-1">
                 <title>Using Zend_Http_Response Accessor Methods</title>
+
                 <programlisting language="php"><![CDATA[
 if ($response->getStatus() == 200) {
   echo "The request returned the following information:<br />";
@@ -183,8 +217,10 @@ if ($response->getStatus() == 200) {
 }
 ]]></programlisting>
             </example>
+
             <note>
                 <title>Always check return value</title>
+
                 <para>
                     Since a response can contain several instances of the same header,
                     the getHeader() method and getHeaders() method may return either a
@@ -192,8 +228,10 @@ if ($response->getStatus() == 200) {
                     always check whether the returned value is a string or array.
                 </para>
             </note>
+
             <example id="zend.http.response.acessors.example-2">
                 <title>Accessing Response Headers</title>
+
                 <programlisting language="php"><![CDATA[
 $ctype = $response->getHeader('Content-type');
 if (is_array($ctype)) $ctype = $ctype[0];
@@ -211,43 +249,54 @@ echo $body;
 
     <sect2 id="zend.http.response.static_parsers">
         <title>Static HTTP Response Parsers</title>
+
         <para>
-            The <classname>Zend_Http_Response</classname> class also includes several internally-used
-            methods for processing and parsing <acronym>HTTP</acronym> response messages. These
-            methods are all exposed as static methods, which means they can be
+            The <classname>Zend_Http_Response</classname> class also includes several
+            internally-used methods for processing and parsing <acronym>HTTP</acronym> response
+            messages. These methods are all exposed as static methods, which means they can be
             used externally, even if you do not need to instantiate a response
             object, and just want to extract a specific part of the response.
+
             <itemizedlist>
                 <listitem>
                     <para>
                         <code>int Zend_Http_Response::extractCode($response_str)</code>: Extract
-                        and return the <acronym>HTTP</acronym> response code (eg. 200 or 404) from $response_str
+                        and return the <acronym>HTTP</acronym> response code (eg. 200 or 404) from
+                        $response_str
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string Zend_Http_Response::extractMessage($response_str)</code>: Extract
-                        and return the <acronym>HTTP</acronym> response message (eg. "OK" or "File Not Found") from $response_str
+                        <code>string Zend_Http_Response::extractMessage($response_str)</code>:
+                        Extract and return the <acronym>HTTP</acronym> response message (eg. "OK" or
+                        "File Not Found") from $response_str
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>string Zend_Http_Response::extractVersion($response_str)</code>: : Extract
-                        and return the <acronym>HTTP</acronym> version (eg. 1.1 or 1.0) from $response_str
+                        <code>string Zend_Http_Response::extractVersion($response_str)</code>:
+                        Extract and return the <acronym>HTTP</acronym> version (eg. 1.1 or 1.0) from
+                        $response_str
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
-                        <code>array Zend_Http_Response::extractHeaders($response_str)</code>: Extract
-                        and return the <acronym>HTTP</acronym> response headers from $response_str as an array
+                        <code>array Zend_Http_Response::extractHeaders($response_str)</code>:
+                        Extract and return the <acronym>HTTP</acronym> response headers from
+                        $response_str as an array
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>string Zend_Http_Response::extractBody($response_str)</code>: Extract
                         and return the <acronym>HTTP</acronym> response body from $response_str
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>string Zend_Http_Response::responseCodeAsText($code = null, $http11 =
@@ -262,9 +311,11 @@ echo $body;
                 </listitem>
             </itemizedlist>
         </para>
+
         <para>
-            Apart from parser methods, the class also includes a set of decoders for common <acronym>HTTP</acronym>
-            response transfer encodings:
+            Apart from parser methods, the class also includes a set of decoders for common
+            <acronym>HTTP</acronym> response transfer encodings:
+
             <itemizedlist>
                 <listitem>
                     <para>
@@ -272,12 +323,14 @@ echo $body;
                         a complete "Content-Transfer-Encoding: Chunked" body
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>string Zend_Http_Response::decodeGzip($body)</code>: Decode
                         a "Content-Encoding: gzip" body
                     </para>
                 </listitem>
+
                 <listitem>
                     <para>
                         <code>string Zend_Http_Response::decodeDeflate($body)</code>: Decode

+ 17 - 17
documentation/manual/en/module_specs/Zend_InfoCard-Basics.xml

@@ -66,8 +66,8 @@
 
         <para>
             Note, Information cards can only be <code>HTTP POST</code>ed to
-            <acronym>SSL</acronym>-encrypted <acronym>URL</acronym>s. Please consult your web server's documentation
-            on how to set up <acronym>SSL</acronym> encryption.
+            <acronym>SSL</acronym>-encrypted <acronym>URL</acronym>s. Please consult your web
+            server's documentation on how to set up <acronym>SSL</acronym> encryption.
         </para>
     </sect2>
 
@@ -140,8 +140,8 @@ if (isset($_POST['xmlToken'])) {
 
         <para>
             In the example above, we first create an instance of the
-            <classname>Zend_Auth_Adapter_InfoCard</classname> and pass the <acronym>XML</acronym> data posted
-            by the card selector into it. Once an instance has been created you
+            <classname>Zend_Auth_Adapter_InfoCard</classname> and pass the <acronym>XML</acronym>
+            data posted by the card selector into it. Once an instance has been created you
             must then provide at least one <acronym>SSL</acronym> certificate public/private key
             pair used by the web server that received the <code>HTTP
             POST</code>. These files are used to validate the destination
@@ -163,9 +163,9 @@ if (isset($_POST['xmlToken'])) {
         <para>
             It is also possible to use the <classname>Zend_InfoCard</classname> component as a
             standalone component by interacting with the
-            <classname>Zend_InfoCard</classname> class directly. Using the <classname>Zend_InfoCard</classname>
-            class is very similar to its use with the <classname>Zend_Auth</classname>
-            component. An example of its use is shown below:
+            <classname>Zend_InfoCard</classname> class directly. Using the
+            <classname>Zend_InfoCard</classname> class is very similar to its use with the
+            <classname>Zend_Auth</classname> component. An example of its use is shown below:
         </para>
 
         <programlisting language="php"><![CDATA[
@@ -209,8 +209,8 @@ if (isset($_POST['xmlToken'])) {
             In the example above, we use the <classname>Zend_InfoCard</classname> component
             independently to validate the token provided by the user. As was the
             case with the <classname>Zend_Auth_Adapter_InfoCard</classname>, we create an
-            instance of <classname>Zend_InfoCard</classname> and then set one or more <acronym>SSL</acronym>
-            certificate public/private key pairs used by the web server. Once
+            instance of <classname>Zend_InfoCard</classname> and then set one or more
+            <acronym>SSL</acronym> certificate public/private key pairs used by the web server. Once
             configured, we can use the <methodname>process()</methodname> method to process
             the information card and return the results.
         </para>
@@ -242,9 +242,9 @@ if (isset($_POST['xmlToken'])) {
             you will need to extract them explicitly using this method (simply
             pass it the full <acronym>URI</acronym> of the claim to retrieve its value from within
             the information card). Generally speaking however, the
-            <classname>Zend_InfoCard</classname> component will set the default <acronym>URI</acronym> for
-            claims to be the one used the most frequently within the information
-            card itself and the simplified property-access method can be used.
+            <classname>Zend_InfoCard</classname> component will set the default
+            <acronym>URI</acronym> for claims to be the one used the most frequently within the
+            information card itself and the simplified property-access method can be used.
         </para>
 
         <para>
@@ -350,11 +350,11 @@ public function submitinfocardAction()
             To prevent this, one must implement the
             <classname>Zend_InfoCard_Adapter_Interface</classname> and set an
             instance of this interface prior to calling either the
-            <methodname>process()</methodname> (standalone) or <methodname>authenticate()</methodname>
-            method as a <classname>Zend_Auth</classname> adapter. To set this interface,
-            the <methodname>setAdapter()</methodname> method should be used. In the example below,
-            we set a <classname>Zend_InfoCard</classname> adapter and use it in our
-            application:
+            <methodname>process()</methodname> (standalone) or
+            <methodname>authenticate()</methodname> method as a <classname>Zend_Auth</classname>
+            adapter. To set this interface, the <methodname>setAdapter()</methodname> method should
+            be used. In the example below, we set a <classname>Zend_InfoCard</classname> adapter and
+            use it in our application:
         </para>
 
         <programlisting language="php"><![CDATA[