<!-- $Id: DisplayFiles.html,v 1.4 2006/12/06 05:15:50 castaglia Exp $ --> <!-- $Source: /cvsroot/proftp/proftpd/doc/howto/DisplayFiles.html,v $ --> <html> <head> <title>ProFTPD mini-HOWTO - Display Files</title> </head> <body bgcolor=white> <hr> <center><h2><b>ProFTPD's <code>Display</code> Files</b></h2></center> <hr> <p> ProFTPD supports a number of configuration directives that specify a file whose contents should be displayed to connected clients at various times: <ul> <li> <dt><code>DisplayConnect</code> <dd>Displayed to clients as soon as they connect</dd> </li> <p> <li> <dt><code>DisplayLogin</code> <dd>Displayed to clients once they have logged in using the <code>USER</code> and <code>PASS</code> commands</dd> </li> <p> <li> <dt><code>DisplayChdir</code> <dd>Displayed to a client whenever it changes into a directory</dd> </li> <p> <li> <dt><code>DisplayGoAway</code> <dd>Displayed to a client when it cannot connect because the maximum number of connections from its <code>Class</code> has been reached</dd> </li> <p> <li> <dt><code>DisplayFileTransfer</code> <dd>Displayed to the client whenever a file is successfully transfer, either uploaded or downloaded</dd> </li> <p> <li> <dt><code>DisplayQuit</code> <dd>Displayed to a client when the session ends via the <code>QUIT</code> command</dd> </li> </ul> <p> Note the subtle difference between <code>DisplayConnect</code> and <code>DisplayLogin</code>. A <code>DisplayConnect</code> file will be displayed to all clients; this makes it suitable for server banners, messages of the day, <i>etc</i>. A <code>DisplayLogin</code> file will only be displayed once the client has logged in. <p> The configured file paths can be either relative or absolute (except in the case of <code>DisplayConnect</code>, which always requires absolute paths). In the case of a relative path, the file is assumed to be in the starting directory a user, <i>i.e.</i> the <code><Anonymous></code> directory for anonymous logins, and the user's home directory for non-anonymous logins. <b>Note</b>: If <code>DefaultRoot</code> is in effect, then the file <b>must</b> reside inside the <code>chroot</code>ed directory. If the configured file cannot be found or accessed, no error occurs and nothing is logged or displayed to the client. <p> <b><code>Display</code> Variables</b><br> The following table contains the variables that can be used in <code>Display</code> files. Be aware that not all of these may have a rational value, depending on the context in which they are used (<i>e.g.</i>, <code>%u</code> if <code>IdentLookups</code> are <em>off</em>). <p> Other <code>contrib</code> modules may provide additional variables for use as well; please consult their documentation for more information. <p> <table border=1> <tr> <td><b>Variable</b></td> <td><b>Meaning</b></td> </tr> <tr> <td>%C</td> <td>Current working directory</td> </tr> <tr> <td>%E</td> <td>Server admin's email address</td> </tr> <tr> <td>%F</td> <td>Available space on file system, in bytes</td> <tr> <tr> <td>%f</td> <td>Available space on file system, with units</td> </tr> <tr> <td>%i</td> <td>The number of files uploaded (input) in this session</td> </tr> <tr> <td>%K</td> <td>Total number of bytes transferred</td> </tr> <tr> <td>%k</td> <td>Total number of bytes transferred, in units</td> </tr> <tr> <td>%L</td> <td>Local hostname</td> </tr> <tr> <td>%M</td> <td>Maximum number of connections</td> </tr> <tr> <td>%N</td> <td>Current number of connections</td> </tr> <tr> <td>%o</td> <td>The number of files downloaded (output) in this session</td> </tr> <tr> <td>%R</td> <td>Remote hostname</td> </tr> <tr> <td>%T</td> <td>Current time</td> </tr> <tr> <td>%t</td> <td>The number of files transferred (uploaded and downloaded) in this session</td> </tr> <tr> <td>%U</td> <td>Username originally used to login</td> </tr> <tr> <td>%u</td> <td>Username reported by ident protocol</td> </tr> <tr> <td>%V</td> <td><code>ServerName</code> of virtual host, if any</td> </tr> <tr> <td>%x</td> <td>The name of the user's <code>Class</code>, if any</td> </tr> <tr> <td>%y</td> <td>Current number of connections from the user's <code>Class</code></td> </tr> <tr> <td>%z</td> <td>Maximum number of connections from the user's <code>Class</code></td> </tr> <tr> <td>%{total_bytes_in}</td> <td>The number of bytes uploaded (input) in this session</td> </tr> <tr> <td>%{total_bytes_out}</td> <td>The number of bytes downloaded (output) in this session</td> </tr> <tr> <td>%{total_bytes_xfer}</td> <td>The number of bytes transferred (uploaded and downloaded) in this session</td> </tr> <tr> <td>%{total_files_in}</td> <td>The number of files uploaded (input) in this session</td> </tr> <tr> <td>%{total_files_out}</td> <td>The number of files downloaded (output) in this session</td> </tr> <tr> <td>%{total_files_xfer}</td> <td>The number of files transferred (uploaded and downloaded) in this session</td> </tr> </table> <p> <hr> <i>$Date: 2006/12/06 05:15:50 $</i><br> </body> </html>