home *** CD-ROM | disk | FTP | other *** search
- /* Sample minimal GoServe filter program */
-
- parse arg source, selector, selector2 /* Get arguments */
- parse var source server port transaction who . /* Often useful */
-
- say who':' selector /* [show filter running] */
-
- drive='d:' /* Data drive */
- dir=drive'\godata'port'\' /* Data root directory (e.g. "d:\godata70\") */
-
- /* This very simple filter just builds the full path name of a file from */
- /* the selector and returns that. Note we do not put the full path in */
- /* menus, as this could allow clients to access all files on the server */
- /* machine, which is rarely desirable. */
-
- if selector='' then selector='mainmenu.'port /* 'startup' case */
- if translate(right(selector,4))='.ZIP' /* use Binary for ZIP files */
- then data='Binary'
- else data='Text'
- return 'File' data 'name' dir''selector
-
-