<INPUT TYPE="TEXT" NAME="f_description" VALUE="<?php echo htmlspecialchars($attachmentObj->getDescription($f_language_selected)); ?> " class="input_text" SIZE="32" <?php p($isReadOnly); ?> > </TD> </TR> <TR> <TD ALIGN="RIGHT"><?php echo $translator->trans('File Size', array(), 'article_files'); ?> :</TD> <TD><?php p(camp_format_bytes($attachmentObj->getSizeInBytes())); ?> </TD> </TR> <TR> <TD ALIGN="left" colspan="2" style="padding-left: 15px;"><?php echo $translator->trans("Should this file only be available for this translation of the article, or for all translations?", array(), 'article_files'); ?> </TD> </TR> <TR> <TD colspan="2" class="indent" style="padding-left: 30px;"> <INPUT type="radio" name="f_language_specific" value="yes" <?php if ($attachmentObj->getLanguageId()) { ?> checked<?php
</TR> <TR> <TD ALIGN="RIGHT"><?php putGS('File Name'); ?>:</TD> <TD><?php echo htmlspecialchars($attachmentObj->getFileName()); ?> <A HREF="/attachment/<?php p(basename($attachmentObj->getStorageLocation())); ?>"><IMG TITLE="<?php putGS('Download'); ?>" BORDER="0" ALIGN="absmiddle" SRC="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]);?>/download.png" /></A></TD> </TR> <TR> <TD ALIGN="RIGHT"><?php putGS('Description'); ?>:</TD> <TD> <INPUT TYPE="TEXT" NAME="f_description" VALUE="<?php echo htmlspecialchars($attachmentObj->getDescription($f_language_selected)); ?>" class="input_text" SIZE="32" <?php p($isReadOnly); ?>> </TD> </TR> <TR> <TD ALIGN="RIGHT"><?php putGS('File Size'); ?>:</TD> <TD><?php p(camp_format_bytes($attachmentObj->getSizeInBytes())); ?></TD> </TR> <TR> <TD ALIGN="left" colspan="2" style="padding-left: 15px;"><?php putGS("Should this file only be available for this translation of the article, or for all translations?"); ?></TD> </TR> <TR> <TD colspan="2" class="indent" style="padding-left: 30px;"> <INPUT type="radio" name="f_language_specific" value="yes" <?php if ($attachmentObj->getLanguageId()) { ?> checked<?php } ?> <?php p($isDisabled); ?>><?php putGS("Only this translation"); ?><br> <INPUT type="radio" name="f_language_specific" value="no" <?php if (!$attachmentObj->getLanguageId()) { ?> checked<?php } ?> <?php p($isDisabled); ?>><?php putGS("All translations"); ?> </TD> </TR> <TR> <TD ALIGN="left" colspan="2" style="padding-left: 15px;"><?php putGS("Do you want this file to open in the user's browser, or to automatically download?"); ?></TD> </TR> <TR> <TD colspan="2" style="padding-left: 30px;">
<?php } ?> <ul class="block-list"> <?php foreach ($articleFiles as $file) { $fileEditUrl = "/$ADMIN/articles/files/edit.php?f_publication_id=$f_publication_id&f_issue_number=$f_issue_number&f_section_number=$f_section_number&f_article_number=$f_article_number&f_attachment_id=".$file->getAttachmentId()."&f_language_id=$f_language_id&f_language_selected=$f_language_selected"; $deleteUrl = "/$ADMIN/articles/files/do_del.php?f_publication_id=$f_publication_id&f_issue_number=$f_issue_number&f_section_number=$f_section_number&f_article_number=$f_article_number&f_attachment_id=".$file->getAttachmentId()."&f_language_selected=$f_language_selected&f_language_id=$f_language_id&".SecurityToken::URLParameter(); $downloadUrl = $file->getAttachmentUrl()."?g_download=1"; $previewUrl = null; if (strstr($file->getMimeType(), "image/") && (strstr($_SERVER['HTTP_ACCEPT'], $file->getMimeType()) || (strstr($_SERVER['HTTP_ACCEPT'], "*/*")))) { $previewUrl = $Campsite['SUBDIR']."/attachment/".basename($file->getStorageLocation())."?g_show_in_browser=1"; } ?> <li> <?php if ($inEditMode) { ?> <a class="text-link" href="<?php echo $fileEditUrl; ?>"><?php echo wordwrap($file->getFileName(), "25", "<br />", true); ?></a> <?php } else { ?> <?php echo wordwrap($file->getFileName(), "25", "<br />", true); ?> <?php } ?> <span class="info"><?php echo htmlspecialchars($file->getDescription($f_language_selected)), ', ', camp_format_bytes($file->getSizeInBytes()); ?></span> <a class="link icon-link" href="<?php p($downloadUrl); ?>"><span class="icon ui-icon-arrowthickstop-1-s"></span><?php putGS('Download'); ?></a> <?php if ($inEditMode && $g_user->hasPermission('DeleteFile')) { ?> <a class="corner-button" href="<?php p($deleteUrl); ?>" onclick="return confirm('<?php putGS("Are you sure you want to remove the file \\'$1\\' from the article?", camp_javascriptspecialchars($file->getFileName())); ?>');"><span class="ui-icon ui-icon-closethick"></span></a> <?php } ?> </li> <?php } ?> </div> </div></div>
"><?php echo wordwrap($file->getFileName(), "25", "<br />", true); ?> </a> <?php } else { ?> <?php echo wordwrap($file->getFileName(), "25", "<br />", true); ?> <?php } ?> <span class="info"><?php echo !$file->getLanguageId() ? htmlspecialchars($file->getDescription($f_language_selected)) : htmlspecialchars($file->getDescription($f_language_selected)), ', ', camp_format_bytes($file->getSizeInBytes()); ?> </span> <a class="link icon-link" href="<?php p($downloadUrl); ?> "><span class="icon ui-icon-arrowthickstop-1-s"></span><?php echo $translator->trans('Download', array(), 'articles'); ?> </a> <?php if ($inEditMode && $g_user->hasPermission('DeleteFile')) { ?> <a class="corner-button" href="<?php p($deleteUrl);
?> ', 'attach_file', 'scrollbars=yes, resizable=yes, menubar=no, toolbar=no, width=500, height=400, top=200, left=100');"><IMG src="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]); ?> /preview-16x16.png" border="0" /></A> <?php } ?> </TD> <?php } ?> </TR> <TR> <TD align="center"><?php p(camp_format_bytes($file->getSizeInBytes())); ?> <A title="<?php putGS("Download"); ?> " href="<?php p($downloadUrl); ?> "><IMG src="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]); ?> /download.png" border="0" /></A></TD> <TD></TD> </TR> </TABLE> </TD>
if (strstr($file->getMimeType(), "image/") && (strstr($_SERVER['HTTP_ACCEPT'], $file->getMimeType()) || (strstr($_SERVER['HTTP_ACCEPT'], "*/*")))) { $previewUrl = "/attachment/".basename($file->getStorageLocation())."?g_show_in_browser=1"; } ?> <TR> <TD align="center" width="100%"> <TABLE> <TR> <TD align="center" valign="top"> <?php if ($f_edit_mode == "edit") { ?><a href="<?php p($fileEditUrl); ?>"><?php } p(wordwrap($file->getFileName(), "25", "<br>", true)); ?><?php if ($f_edit_mode == "edit") { ?></a><?php } ?><br><?php p(htmlspecialchars($file->getDescription($f_language_selected))); ?> </TD> <?php if ($g_user->hasPermission('DeleteFile')) { ?> <TD> <A title="<?php putGS("Delete"); ?>" href="<?php p($deleteUrl); ?>" onclick="return confirm('<?php putGS("Are you sure you want to remove the file \\'$1\\' from the poll answer?", camp_javascriptspecialchars($file->getFileName())); ?>');"><IMG src="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]);?>/unlink.png" border="0" /></A><BR /> <?php if (!empty($previewUrl)) { ?> <A title="<?php putGS("Preview"); ?>" href="javascript: void(0);" onclick="window.open('<?php echo $previewUrl; ?>', 'attach_file', 'scrollbars=yes, resizable=yes, menubar=no, toolbar=no, width=500, height=400, top=200, left=100');"><IMG src="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]);?>/preview-16x16.png" border="0" /></A> <?php } ?> </TD> <?php } ?> </TR> <TR> <TD align="center"><?php p(camp_format_bytes($file->getSizeInBytes())); ?> <A title="<?php putGS("Download"); ?>" href="<?php p($downloadUrl); ?>"><IMG src="<?php p($Campsite["ADMIN_IMAGE_BASE_URL"]);?>/download.png" border="0" /></A></TD> <TD></TD> </TR> </TABLE> </TD> </TR> <?php } ?> </TABLE> </center>