docs.roxen.comView this page in a printer friendly mode
DocsRoxenWebServer 4.5Web Developer ManualIf Tags
Copyright © 2012, Roxen Internet Software
Suggestions, comments & compliments
manuals@roxen.com
 DEMO  DOCS  PIKE
 COMMUNITY  DOWNLOAD
www.roxen.com

   

<else>
<elseif>
<false>
<if>
<if accept>
<if client>
<if clientvar>
<if config>
<if cookie>
<if date>
<if defined>
<if domain>
<if exists>
<if expr>
<if false>
<if group>
<if internal-exists>
<if ip>
<if kerberos-auth>
<if language>
<if match>
<if Match>
<if module>
<if pragma>
<if prestate>
<if referrer>
<if sizeof>
<if supports>
<if time>
<if true>
<if type-from-data>
<if type-from-filename>
<if user>
<if variable>
<if Variable>
<then>
<true>

<if exists></if>

Provided by module: Tags: RXML 2 tags

Returns true if the named page is viewable. A nonviewable page is e.g. a file that matches the internal files patterns in the filesystem module. If the path does not begin with /, it is assumed to be a URL relative to the directory containing the page with the <if>-statement. 'Magic' files like /internal-roxen-unit will evaluate as true. This is a State plugin.

To check if a path supplied via e.g. a form exists you could combine the -exists plugin with e.g. the sizeof-plugin:


  <if exists='&form.path;' and='' sizeof='form.path > 0'>
    The path &form.path; exists in the virtual filesystem.
  </if>

Attributes

exists="path"

Choose what path in the virtual filesystem to test.