XXXVIII. Hyperwave functions

Introduction

It started with the name Hyper-G and changed to Hyperwave when it was commercialised ( If I remember properly it was in 1996 ) .

The current version , 4.1 , is available at www.hyperwave.com .

In order to gain the original document you will have to retrieve the plain document without the links and the list of links and reinsert them ( The functions hw_pipedocument( ) and hw_gettext( ) do this for you .

Hyperwave object with name ' my_object ' is mapped to 'http : / /host / my_object ' disregarding where it resides in the Hyperwave hierarchy . An object with name ' parent / my_object ' could be the child of 'my_object ' in the Hyperwave hierarchy , though in a web namespace it appears to be just the opposite and the user might get confused .

The URL http : / /host / my_object will not call any PHP 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 . 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 .

Therefore ' / ' has to be replaced by another character , e.g . '_ ' . to be continued .

  • An associated array with all attributes of an object . The key is the attribute name . If an attribute occurs more than once in an object record it will result in another indexed or associated array . Attributes which are language depended ( like the title , keyword , description ) will form an associated array with the key set to the language abbreviation .

  • It is somewhat optimised for HTML documents but may be used for any format .



Several functions which return an array of object records do also return an associated array with statistical information about them .

Hidden

CollectionHead

FullCollectionHead

CollectionHeadNr

FullCollectionHeadNr

Total



Integration with Apache

Since PHP with Hyperwave support built into Apache is intended to replace the native Hyperwave solution based on Wavemaster I will assume that the Apache server will only serve as a Hyperwave web interface . First of all you need a PHP script which evaluates the PATH_INFO variable and treats its value as the name of a Hyperwave object . The URL http : / /your.hostname / Hyperwave / name_of_object The URL http : / /your.hostname / Hyperwave / name_of_object would than return the Hyperwave object with the name ' name_of_object ' . From the users point of view it would be more straight forward if the URL http : / /your.hostname / name_of_object would return the object .

Now every URL relates to an object in the Hyperwave server. This causes a simple to solve problem. There is no way to execute a different script, e.g. for searching, than the 'Hyperwave' script. This can be fixed with another rewriting rule like the following: This will reserve the directory /usr/local/apache/htdocs/hw for additional scripts and other files. Just make sure this rule is evaluated before the one above. There is just a little drawback: all Hyperwave objects whose name starts with 'hw/' will be shadowed. So, make sure you don't use such names. If you need more directories, e.g. for images just add more rules or place them all in one directory. Finally, don't forget to turn on the rewriting engine with My experiences have shown that you will need the following scripts:


Todo

There are still some things todo :



תוכן העניינים:
hw_Array2Objrec -- convert attributes from object array to object record
hw_changeobject -- Changes attributes of an object (obsolete)
hw_Children -- object ids of children
hw_ChildrenObj -- object records of children
hw_Close -- closes the Hyperwave connection
hw_Connect -- opens a connection
hw_connection_info -- Prints information about the connection to Hyperwave server
hw_Cp -- copies objects
hw_Deleteobject -- deletes object
hw_DocByAnchor -- object id object belonging to anchor
hw_DocByAnchorObj -- object record object belonging to anchor
hw_Document_Attributes -- object record of hw_document
hw_Document_BodyTag -- body tag of hw_document
hw_Document_Content -- returns content of hw_document
hw_Document_SetContent -- sets/replaces content of hw_document
hw_Document_Size -- size of hw_document
hw_dummy -- Hyperwave dummy function
hw_EditText -- retrieve text document
hw_Error -- error number
hw_ErrorMsg -- returns error message
hw_Free_Document -- frees hw_document
hw_GetAnchors -- object ids of anchors of document
hw_GetAnchorsObj -- object records of anchors of document
hw_GetAndLock -- return bject record and lock object
hw_GetChildColl -- object ids of child collections
hw_GetChildCollObj -- object records of child collections
hw_GetChildDocColl -- object ids of child documents of collection
hw_GetChildDocCollObj -- object records of child documents of collection
hw_GetObject -- object record
hw_GetObjectByQuery -- search object
hw_GetObjectByQueryColl -- search object in collection
hw_GetObjectByQueryCollObj -- search object in collection
hw_GetObjectByQueryObj -- search object
hw_GetParents -- object ids of parents
hw_GetParentsObj -- object records of parents
hw_getrellink -- Get link from source to dest relative to rootid
hw_GetRemote -- Gets a remote document
hw_GetRemoteChildren -- Gets children of remote document
hw_GetSrcByDestObj -- Returns anchors pointing at object
hw_GetText -- retrieve text document
hw_getusername -- name of currently logged in user
hw_Identify -- identifies as user
hw_InCollections -- check if object ids in collections
hw_Info -- info about connection
hw_InsColl -- insert collection
hw_InsDoc -- insert document
hw_insertanchors -- Inserts only anchors into text
hw_InsertDocument -- upload any document
hw_InsertObject -- inserts an object record
hw_mapid -- Maps global id on virtual local id
hw_Modifyobject -- modifies object record
hw_Mv -- moves objects
hw_New_Document -- create new document
hw_Objrec2Array -- convert attributes from object record to object array
hw_Output_Document -- prints hw_document
hw_pConnect -- make a persistent database connection
hw_PipeDocument -- retrieve any document
hw_Root -- root object id
hw_setlinkroot -- Set the id to which links are calculated
hw_stat -- Returns status string
hw_Unlock -- unlock object
hw_Who -- List of currently logged in users