/usr/share/doc/mhonarc/resources/attachmentdir.html is in mhonarc 2.6.18-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 | <html>
<head>
<title>MHonArc Resources: ATTACHMENTDIR</title>
<link rel="stylesheet" type="text/css" href="../docstyles.css">
</head>
<body>
<!--x-rc-nav-->
<table border=0><tr valign="top">
<td align="left" width="50%">[Prev: <a href="archive.html">ARCHIVE</a>]</td><td><nobr>[<a href="../resources.html#attachmentdir">Resources</a>][<a href="../mhonarc.html">TOC</a>]</nobr></td><td align="right" width="50%">[Next: <a href="attachmenturl.html">ATTACHMENTURL</a>]</td></tr></table>
<!--/x-rc-nav-->
<hr>
<h1>ATTACHMENTDIR</h1>
<!--X-TOC-Start-->
<ul>
<li><a href="#syntax">Syntax</a>
<li><a href="#description">Description</a>
<li><a href="#default">Default Setting</a>
<li><a href="#rcvars">Resource Variables</a>
<li><a href="#examples">Examples</a>
<li><a href="#version">Version</a>
<li><a href="#seealso">See Also</a>
</ul>
<!--X-TOC-End-->
<!-- *************************************************************** -->
<hr>
<h2><a name="syntax">Syntax</a></h2>
<dl>
<dt><strong>Envariable</strong></dt>
<dd><p>
<code>M2H_ATTACHMENTDIR=</code><var>pathname</var>
</p>
</dd>
<dt><strong>Element</strong></dt>
<dd><p>
<code><ATTACHMENTDIR></code><br>
<var>pathname</var><br>
<code></ATTACHMENTDIR></code><br>
</p>
</dd>
<dt><strong>Command-line Option</strong></dt>
<dd><p>
<code>-attachmentdir </code><var>pathname</var>
</p>
</dd>
</dl>
<!-- *************************************************************** -->
<hr>
<h2><a name="description">Description</a></h2>
<p>ATTACHMENTDIR specifies the pathname directory location attachments
will be saved. If ATTACHMENTDIR is a relative pathname, it will
be relative to <a href="outdir.html">OUTDIR</a>. For example, if
OUTDIR is set to:
</p>
<pre>
/var/www/html/archive
</pre>
<p>And ATTACHMENTDIR is set to:
</p>
<pre>
attachments
</pre>
<p>Then attachment files will be saved to
</p>
<pre>
/var/www/html/archive/attachments
</pre>
<p>If ATTACHMENTDIR
is not set, attachments will be saved in <a href="outdir.html">OUTDIR</a>.
</p>
<p>When defining ATTACHMENTDIR, the
<a href="attachmenturl.html">ATTACHMENTURL</a> resource should
also be set.
</p>
<!-- *************************************************************** -->
<hr>
<h2><a name="default">Default Setting</a></h2>
<p><i>Nil</i>.
</p>
<!-- *************************************************************** -->
<hr>
<h2><a name="rcvars">Resource Variables</a></h2>
<p>N/A
</p>
<!-- *************************************************************** -->
<hr>
<h2><a name="examples">Examples</a></h2>
<p>By default, attachment files are written in the same directory
as message and index pages. However, if you would like to have
all attachments written in a sub-directory of the archive directory,
you can do something like the following:
</p>
<pre class="code">
<!-- Have attachments written to a sub-directory -->
<b><AttachmentDir></b>
attachments
<b></AttachmentDir></b>
<!-- Define base URL to attachment directory. -->
<b><<a href="attachmenturl.html">AttachmentURL</a>></b>
attachments
<b></AttachmentURL></b>
</pre>
<p>Notice how <a href="attachmenturl.html">ATTACHMENTURL</a>
is equal to ATTACHMENTDIR. When ATTACHMENTDIR is set to a
relative pathname, ATTACHMENTURL should be set to the same
value. This way, if archive files are moved to a different
location on the file system, links to attachments will not break.
</p>
<p>If maintaining multiple archives, and to provide for
better security, you may want have all attachments for all archives
written to a single location. The attachment location can then have more
restrictive HTTP server and file system settings to provide further
protection against malicious attachments.
</p>
<p>The following example shows ATTACHMENTDIR being set to
a central location and then defining
<a href="attachmenturl.html">ATTACHMENTURL</a> so MHonArc knows
what base URL to use when creating links to attachment files:
</p>
<pre class="code">
<!-- Have all attachments written to central location -->
<b><AttachmentDir></b>
/var/www/html/archives/attachments
<b></AttachmentDir></b>
<!-- Define base URL to attachment directory. -->
<b><<a href="attachmenturl.html">AttachmentURL</a>></b>
/archives/attachments
<b></AttachmentURL></b>
</pre>
<p>In this case, <a href="attachmenturl.html">ATTACHMENTURL</a>
does not equal ATTACHMENTDIR since ATTACHMENTDIR is a full pathname.
Therefore, ATTACHMENTURL must be set to a value tha HTTP server
will resolve to the value of ATTACHMENTDIR.
</p>
<table class="note" width="100%">
<tr valign="baseline">
<td><strong>NOTE:</strong></td>
<td width="100%"><p>In this example,
we do not include the "<tt>http://<i>hostname</i></tt>" part
of the URL since attachment files will be served up from the
same HTTP server as other archive pages.
</p>
</td>
</tr>
</table>
<!-- *************************************************************** -->
<hr>
<h2><a name="version">Version</a></h2>
<p>2.6.9
</p>
<!-- *************************************************************** -->
<hr>
<h2><a name="seealso">See Also</a></h2>
<p>
<a href="attachmenturl.html">ATTACHMENTURL</a>,
<a href="outdir.html">OUTDIR</a>
</p>
<!-- *************************************************************** -->
<hr>
<!--x-rc-nav-->
<table border=0><tr valign="top">
<td align="left" width="50%">[Prev: <a href="archive.html">ARCHIVE</a>]</td><td><nobr>[<a href="../resources.html#attachmentdir">Resources</a>][<a href="../mhonarc.html">TOC</a>]</nobr></td><td align="right" width="50%">[Next: <a href="attachmenturl.html">ATTACHMENTURL</a>]</td></tr></table>
<!--/x-rc-nav-->
<hr>
<address>
$Date: 2003/10/06 22:04:16 $<br>
<img align="top" src="../monicon.png" alt="">
<a href="http://www.mhonarc.org/"><strong>MHonArc</strong></a><br>
Copyright © 2003, <a href="http://www.earlhood.com/"
>Earl Hood</a>, <a href="mailto:mhonarc%40mhonarc.org"
>mhonarc<!--
-->@<!--
-->mhonarc.org</a><br>
</address>
</body>
</html>
|