%TMPL:INCLUDE{"twiki"}%



%TMPL:DEF{"script"}%
<script type="text/javascript">
<!--HIDE
	function initForm() {
	   document.main.filepath.focus();
	}
	function launchWindow( theWeb, theTopic ) {
	  win = open("%SCRIPTURLPATH%/view%SCRIPTSUFFIX%/" + theWeb + "/" + theTopic + "?skin=plain", theTopic, "titlebar=0,width=500,height=480,resizable,scrollbars");
	  if( win ) {
		win.focus();
	  }
	  return false;
	}
//STOP HIDING-->
</script> %TMPL:END%



%TMPL:DEF{"bodystart"}%
<body class="twikiNoViewPage twikiAttachPage" onload="initForm()"><a name="PageTop"></a>%TMPL:END%



%TMPL:DEF{"titleaction"}%(attach) %TMPL:END%



%TMPL:DEF{"simpleheader"}%
---+ Attach image or document on %TOPIC% %TMPL:END%



%TMPL:DEF{"notes"}%
   * *Help:* Please see %TWIKIWEB%.FileAttachment for more information about attaching files.
   * *Bug:* Internet Explorer 4.0 or earlier: If you get an "Internal Server Error" message when you upload a file, you need to try again. It should work the second time.
%TMPL:END%



%TMPL:DEF{"content"}%
<form name="main" enctype="multipart/form-data" action="%SCRIPTURLPATH%/upload%SCRIPTSUFFIX%/%INTURLENCODE{"%WEB%/%TOPIC%"}%" method="post">
%TMPL:P{"simpleheader"}%

<div>
%TMPL:P{"previousdetails"}%
<div class="twikiVersatileTable">
<table width="100%">%TMPL:P{"previous"}% 
	<tr>
		<th>
			Local file 
		</th>
		<td class="twikiMainCol">
			<input type="hidden" name="filename" value="%FILENAME%" /><input type="file" name="filepath" value="%FILEPATH%" size="30" /> 
		</td>
		<td class="twikiHelpCol twikiMainCol">
Upload up to %ATTACHFILESIZELIMIT% KB.
		</td>
	</tr>
	<tr>
		<th>
			Comment 
		</th>
		<td>
			<input class="comment" type="text" name="filecomment" value="%FILECOMMENT%" maxlength="256" size="50" /> 
		</td>
		<td class="twikiHelpCol"></td>
	</tr>
	<tr>
		<th>
			Link 
		</th>
		<td>
			<input type="checkbox" class="twikiCheckbox" id="createlink" name="createlink" %ATTACHLINKBOX% /><label for="createlink">Create a link to the attached file</label>
		</td>
		<td class="twikiHelpCol">
Images will be displayed, for other attachments a link will be created.
		</td>
	</tr>
	<tr>
		<th>
			Hide file 
		</th>
		<td>
			<input type="checkbox" class="twikiCheckbox" id="hidefile" name="hidefile" %HIDEFILE% /><label for="hidefile">Do not show attachment in table</label>
		</td>
		<td class="twikiHelpCol">Attachments will not be shown in topic view page.</td>
	</tr>
</table>
</div>
%TMPL:P{"topicaction"}%</form>
<div class="twikiHelp twikiGrayText">
%TMPL:P{"notes"}%
%TMPL:P{"extranotes"}%</div></div>
---++ Existing attachments for <span class="twikiTitle"><nop>%TOPIC%</span>
%META{"attachments" all="on"}%
%TMPL:P{"standardfooter"}%%TMPL:END%



%TMPL:DEF{"attach"}%
%TMPL:P{"htmldoctype"}%
%TMPL:P{"head"}%
%TMPL:P{"bodystart"}%
%TMPL:P{"main"}%
%TMPL:P{"bodyend"}%
%TMPL:END%