%TMPL:INCLUDE{"attach"}%
%TMPL:DEF{"logo"}%%TMPL:END%


%TMPL:DEF{"bodyclassname"}%patternNoViewPage patternAttachPage%TMPL:END%


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


%TMPL:DEF{"pagetitle"}%%MAKETEXT{"Attach image or document on [_1]" args="[[%TOPIC%]]"}%%TMPL:END%


%TMPL:DEF{"toolbar"}%<div class="patternTop">%TWISTYBUTTON{
id="attachhelp"
remember="on"
noscript="hide"
showlink="%MAKETEXT{"Show attachments help"}%"
hidelink="%MAKETEXT{"Hide help"}%"
showimgleft="%ICONURLPATH{toggleopen}%"
hideimgleft="%ICONURLPATH{toggleclose}%"  
linkclass="patternTwistyButton"
}%%TMPL:P{"pagehelp"}%</div>%TMPL:END%


%TMPL:DEF{"pagehelp"}%%TWISTYTOGGLE{
id="attachhelp"
remember="on"
class="foswikiHelp"
}%
%TMPL:P{"notes"}%
%TMPL:P{"extranotes"}%%ENDTWISTYTOGGLE%%TMPL:END%


%TMPL:DEF{"formstart"}%<form name="main" enctype="multipart/form-data" action="%SCRIPTURLPATH{"upload"}%/%WEB%/%TOPIC%" method="post">%TMPL:END%

%TMPL:DEF{"formend"}%</form>%TMPL:END%


%TMPL:DEF{"newfile"}%<div class="foswikiFormStep">
---+++ %MAKETEXT{"Attach new file"}%

%TMPL:P{"previous"}%%IF{"$ATTACHFILESIZELIMIT > 0" then="%MAKETEXT{"Upload up to [_1] KB." args="%ATTACHFILESIZELIMIT%"}%"}%

<noautolink><input type="hidden" name="filename" value="%FILENAME%" />
<input class="foswikiFileInput" type="file" name="filepath" value="%FILEPATH%" size="70" multiple /></noautolink>
</div>
%TMPL:P{context="BatchUploadPluginEnabled" then="batchupload"}%%TMPL:END%

%TMPL:DEF{"batchupload"}%<div class="foswikiFormStep">
---+++ %MAKETEXT{"Upload multiple attachments in one zip file"}%
<p><input type="checkbox" class="foswikiCheckbox" id="batchupload" checked name="batchupload" %BATCHUPLOADCHECKBOX% /><label for="batchupload">%MAKETEXT{"In case of a zip file, attach all included files to this topic"}%</label> <span class="foswikiGrayText">%MAKETEXT{"Leave unchecked if you wish to attach the zip file itself"}%</span></p>
</div>%TMPL:END%

%TMPL:DEF{"comment"}%<div class="foswikiFormStep">
---+++ %MAKETEXT{"Comment"}%
<p>
%MAKETEXT{"Describe the file so other people know what it is."}%
</p>
<input class="foswikiInputField" type="text" name="filecomment" value="%FILECOMMENT%" size="70" />
</div>%TMPL:END%

%TMPL:DEF{"properties"}%<div class="foswikiFormStep">%TMPL:P{"properties::content"}%</div>%TMPL:P{"changepropertiesaction"}%%TMPL:END%

%TMPL:DEF{"properties::content"}%
%TMPL:P{"properties::title"}%
%TMPL:P{"properties::createlink"}%
%TMPL:P{"properties::hidefile"}%
%TMPL:END%

%TMPL:DEF{"properties::title"}%---+++ %MAKETEXT{"Properties"}%%TMPL:END%

%TMPL:DEF{"properties::createlink"}%
<input type="checkbox" class="foswikiCheckbox" id="createlink" name="createlink" %ATTACHLINKBOX% /><label for="createlink">%MAKETEXT{"Create a link to the attached file"}%</label> <span class="foswikiGrayText">%MAKETEXT{"Images will be displayed, for other attachments a link will be created."}%</span>%TMPL:END%

%TMPL:DEF{"properties::hidefile"}%
<input type="checkbox" class="foswikiCheckbox" id="hidefile" name="hidefile" %HIDEFILE% /><label for="hidefile">%MAKETEXT{"Do not show attachment in table"}%</label> <span class="foswikiGrayText">%MAKETEXT{"Attachments will not be shown in topic view page."}%</span>%TMPL:END%


%TMPL:DEF{"attachformend"}%%TMPL:END%


%TMPL:DEF{"attachform"}%<div class="foswikiFormSteps">%TMPL:P{"newfile"}%%TMPL:P{"comment"}%%TMPL:P{"properties"}%%TMPL:P{"hiddenfields"}%%TMPL:P{"attachformend"}%%TMPL:P{"topicactionbuttonsrow"}%</div>%TMPL:END%

%TMPL:DEF{"content"}%%TMPL:P{"toolbar"}%
%TMPL:P{"formstart"}%
%TMPL:P{"attachform"}%
%TMPL:P{"formend"}%
%TMPL:P{"movedelete"}%
%TMPL:P{"versions"}%
%TMPL:P{"existingattachments"}%%TMPL:END%
