CVS update: php3/doc/functions

From: Date: Fri, 13 Nov 1998 09:57:47 +0000
Subject: CVS update: php3/doc/functions
Groups: php.dev 
Request: Send a blank email to php-dev+get-2365@lists.php.net to get a copy of this message
Date: Friday November 13, 1998 @ 4:57 Author: steinm Update of /repository/php3/doc/functions In directory asf:/u2/tmp/cvs-serv29086/doc/functions Modified Files: hw.sgml Log Message: - Ups, the '\* {{{' missed the closing brackets - More docs for Hyperwave Index: php3/doc/functions/hw.sgml diff -c php3/doc/functions/hw.sgml:1.9 php3/doc/functions/hw.sgml:1.10 *** php3/doc/functions/hw.sgml:1.9 Wed Nov 11 12:42:25 1998 --- php3/doc/functions/hw.sgml Fri Nov 13 04:57:47 1998 *************** *** 44,49 **** --- 44,97 ---- at all. You may even add a link to a document without modifying the document itself. <para> + Saying that <function>hw_pipedocument</function> and + <function>hw_gettext</function> do the link insertion automatically + is not as simple as it sounds. Inserting links implies a certain + hierachy of the documents. On a web server this is given by the + file system, but Hyperwave has its own hierachy and names do not + reflect the position of an object in that hierachy. Therefore + creation of links first of all requires a mapping from the Hyperwave + hierachy and namespace into a web hierachy respective web namespace. + The fundamental difference between Hyperwave and the web is the clear + distingtion between names and hierachy in Hyperwave. The name does + not contain any information about the objects position in the hierachy. + In the web the + name also contains the information on where the object is located + in the hierachy. This leads to two possibles ways of mapping. Either + the Hyperwave hierachy and name of the Hyperwave object is reflected + in the URL or the name only. + To make things simple the second approach is used. + Hyperwave object with name 'my_object' is mapped to + 'http://host/my_object' diregarding where it resides in the + Hyperwave hierachy. + An object with name 'parent/my_object' could be the child of + 'my_object' in the Hyperwave hierachy, though in a web namespace it + appears to be just the opposite and the user might get confused. + This can only be prevented by selecting reasonable obect names. + <para> + Having made this decission a second problem arises. How do you + involve php3? The URL http://host/my_object will not call any + php3 script unless you tell your web server to rewrite it to + e.g. 'http://host/php3_script/my_object' and the script 'php3_script' + evaluates the $PATH_INFO variable and retrieves the object with + name 'my_object' from the Hyperwave server. Their is just one little + drawback which can be fixed easily. Rewriting any URL would not allow + any access to other document on the web server. A php3 script for + searching in the Hyperwave server would be impossible. Therefore + you will need at least a second rewriting rule to exclude certain + URLS like all e.g. starting with http://host/Hyperwave. This is + basically sharing of a namespace by the web and Hyperwave server. + <para> + Based on the above mechanism links are insert into documents. + <para> + It gets more complicated if php3 is not run as a module/CGI script + but as a standalone application e.g. to dump the content of the + Hyperwave server on a CD-ROM. In such a case it makes sense to + retain the Hyperwave hierachy and map in onto the filesystem. This + conflicts with the object names if they reflect its own hierachy + (e.g. by chosing names including '/'). Therefore '/' has to be + replaced by another character, e.g. '_'. to be continued. + <para> The network protocol to communicate with the Hyperwave server is called <ulink url="http://www.hyperwave.de/hg-csp-0xc31b08d4">HG-CSP</ulink> *************** *** 464,470 **** <title>Description</title> <funcsynopsis> <funcdef>string <function>hw_documentattributes</function></funcdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Returns the object record of the document. --- 512,518 ---- <title>Description</title> <funcsynopsis> <funcdef>string <function>hw_documentattributes</function></funcdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Returns the object record of the document. *************** *** 483,489 **** <title>Description</title> <funcsynopsis> <funcdef>string <function>hw_documentbodytag</function></funcdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Returns the BODY tag of the document. If the document is an HTML --- 531,537 ---- <title>Description</title> <funcsynopsis> <funcdef>string <function>hw_documentbodytag</function></funcdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Returns the BODY tag of the document. If the document is an HTML *************** *** 503,509 **** <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_documentsize</function></funcdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Returns the size in bytes of the document. --- 551,557 ---- <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_documentsize</function></funcdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Returns the size in bytes of the document. *************** *** 539,547 **** <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>hw_document <function>hw_edittext</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Uploads the text document to the server. The object record --- 587,595 ---- <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>int <function>hw_edittext</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Uploads the text document to the server. The object record *************** *** 586,592 **** <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_free_document</function></funcdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Frees the memory occupied by the Hyperwave document. --- 634,640 ---- <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_free_document</function></funcdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Frees the memory occupied by the Hyperwave document. *************** *** 749,755 **** <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>hw_document <function>hw_gettext</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>objectID</parameter></paramdef> <paramdef>int <parameter>rootID</parameter></paramdef> --- 797,803 ---- <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>int <function>hw_gettext</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>objectID</parameter></paramdef> <paramdef>int <parameter>rootID</parameter></paramdef> *************** *** 761,771 **** The optional parameter <parameter>rootID</parameter> determines how links are inserted into the document. The default is 0 and will result in links that ! are constructed from the name of the link's destination object. If ! <parameter>rootID</parameter> is unequal to 0 the link is constructed from all the names starting at the object with the id <parameter>rootID</parameter> separated by a slash relative to the current object. This function will only work for pure text documents. It will not open a special data connection and therefore blocks the control connection during the transfer. --- 809,835 ---- The optional parameter <parameter>rootID</parameter> determines how links are inserted into the document. The default is 0 and will result in links that ! are constructed from the name of the link's destination object. This ! is useful for web applications. If a link points to an object with ! name 'internet_movie' the HTML link will be ! &lt;A HREF="/internet_movie">. The actual location of the source and ! destination object in the document hierachy is disregarded. You ! will have to set up your web browser, to rewrite that URL to for ! example '/my_script.php3/internet_movie'. 'my_script.php3' will ! have to evaluate $PATH_INFO and retrieve the document. ! <para> ! If <parameter>rootID</parameter> is unequal to 0 the link is constructed from all the names starting at the object with the id <parameter>rootID</parameter> separated by a slash relative to the current object. + If for example the above document 'internet_movie' is located + at 'a-b-c-internet_movie' with '-' being the seperator between + hierachy levels and the source document is located at + 'a-b-d-source' the resulting HTML link would be: + &lt;A HREF="../c/internet_movie">. This is useful if you want + to download the whole server content onto disk and map + the document hierachy onto the file system. + <para> This function will only work for pure text documents. It will not open a special data connection and therefore blocks the control connection during the transfer. *************** *** 1113,1119 **** <funcdef>int <function>hw_putdocument</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>parent_id</parameter></paramdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Uploads a document into the collection with --- 1177,1183 ---- <funcdef>int <function>hw_putdocument</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>parent_id</parameter></paramdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Uploads a document into the collection with *************** *** 1136,1148 **** <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>hw_document <function>hw_new_document</function></funcdef> <paramdef>string <parameter>document_data</parameter></paramdef> <paramdef>string <parameter>object_record</parameter></paramdef> <paramdef>int <parameter>document_size</parameter></paramdef> </funcsynopsis> <para> ! Returns a new document with document data set to <parameter>document_data</parameter> and object record set to <parameter>object_record</parameter>. The length of the <parameter>document_data</parameter> has to passed in --- 1200,1212 ---- <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>int <function>hw_new_document</function></funcdef> <paramdef>string <parameter>document_data</parameter></paramdef> <paramdef>string <parameter>object_record</parameter></paramdef> <paramdef>int <parameter>document_size</parameter></paramdef> </funcsynopsis> <para> ! Returns a new Hyperwave document with document data set to <parameter>document_data</parameter> and object record set to <parameter>object_record</parameter>. The length of the <parameter>document_data</parameter> has to passed in *************** *** 1182,1188 **** <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_outputdocument</function></funcdef> ! <paramdef>hw_document <parameter>document</parameter></paramdef> </funcsynopsis> <para> Prints the document without the BODY tag. --- 1246,1252 ---- <title>Description</title> <funcsynopsis> <funcdef>int <function>hw_outputdocument</function></funcdef> ! <paramdef>int <parameter>hw_document</parameter></paramdef> </funcsynopsis> <para> Prints the document without the BODY tag. *************** *** 1227,1244 **** <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>hw_document <function>hw_pipedocument</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>objectID</parameter></paramdef> </funcsynopsis> <para> ! Returns the document with object ID <parameter>objectID</parameter>. ! If the document has anchors which can be inserted, they will have been inserted already. The document will be transfered via a special data connection which does not block the control connection. <para> ! See also <function>hw_GetText</function>, <function>hw_FreeDocument</function>, <function>hw_DocumentSize</function>, <function>hw_DocumentBodyTag</function>, --- 1291,1308 ---- <refsect1> <title>Description</title> <funcsynopsis> ! <funcdef>int <function>hw_pipedocument</function></funcdef> <paramdef>int <parameter>connection</parameter></paramdef> <paramdef>int <parameter>objectID</parameter></paramdef> </funcsynopsis> <para> ! Returns the Hyperwave document with object ID ! <parameter>objectID</parameter>. If the document has anchors which can be inserted, they will have been inserted already. The document will be transfered via a special data connection which does not block the control connection. <para> ! See also <function>hw_GetText</function> for more on link insertion, <function>hw_FreeDocument</function>, <function>hw_DocumentSize</function>, <function>hw_DocumentBodyTag</function>, -- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net For help: php-dev-help@lists.php.net

« previous php.dev (#2365) next »