#1794 HTML UI: Confirmation needed on successful file upload

This commit is contained in:
sebastian 2010-02-11 16:09:58 +00:00
parent 073b51c2dc
commit 875f17ea85
3 changed files with 8 additions and 6 deletions

View File

@ -1,7 +1,7 @@
{include file="popup/header.tpl"} {include file="popup/header.tpl"}
<center> <center>
{tra str='Are you sure to remove "$1"?' 1=$_REQUEST.login} {tra str='Are you sure you want to delete "$1"?' 1=$_REQUEST.login}
<br><br> <br><br>
<input type="button" class="button" onClick="window.close()" value="Cancel"> <input type="button" class="button" onClick="window.close()" value="Cancel">
<input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=SUBJECTS.removeSubj&login={$_REQUEST.login|escape:'url'}'" value="OK"> <input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=SUBJECTS.removeSubj&login={$_REQUEST.login|escape:'url'}'" value="OK">

View File

@ -3,12 +3,12 @@
<center> <center>
{if $filecount} {if $filecount}
{tra str='Are you sure to delete $1 selected files?' 1=$filecount} {tra str='Are you sure you want to delete $1 selected items?' 1=$filecount}
<br><br> <br><br>
<input type="button" class="button" onClick="window.close()" value="Cancel"> <input type="button" class="button" onClick="window.close()" value="Cancel">
<input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=delete{$idstr}'" value="OK"> <input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=delete{$idstr}'" value="OK">
{else} {else}
{tra str='Are you sure to delete file "$1"?' 1=$filename} {tra str='Are you sure you want to delete "$1"?' 1=$filename}
<br><br> <br><br>
<input type="button" class="button" onClick="window.close()" value="Cancel"> <input type="button" class="button" onClick="window.close()" value="Cancel">
<input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=delete&id={$_REQUEST.id}'" value="OK"> <input type="button" class="button" onClick="location.href='{$UI_HANDLER}?act=delete&id={$_REQUEST.id}'" value="OK">

View File

@ -195,6 +195,7 @@ class uiHandler extends uiBase {
$this->redirUrl = UI_BROWSER."?act=addFileMData&id=".$storedFile->getId(); $this->redirUrl = UI_BROWSER."?act=addFileMData&id=".$storedFile->getId();
$this->_retMsg('Audioclip has been uploaded successfully.'); $this->_retMsg('Audioclip has been uploaded successfully.');
$this->_retMsg('Now please complete metadata about the clip.');
return $storedFile->getId(); return $storedFile->getId();
} // fn uploadFile } // fn uploadFile
@ -295,6 +296,7 @@ class uiHandler extends uiBase {
$this->redirUrl = UI_BROWSER."?act=addWebstreamMData&id=$r"; $this->redirUrl = UI_BROWSER."?act=addWebstreamMData&id=$r";
$this->_retMsg('Webstream data has been saved.'); $this->_retMsg('Webstream data has been saved.');
$this->_retMsg('Now please complete metadata about the clip.');
return $r; return $r;
} // fn addWebstream } // fn addWebstream
@ -314,7 +316,7 @@ class uiHandler extends uiBase {
$this->setMetadataValue($id, UI_MDATA_KEY_DURATION, $extent); $this->setMetadataValue($id, UI_MDATA_KEY_DURATION, $extent);
$this->redirUrl = UI_BROWSER.'?act=editItem&id='.$formdata['id']; $this->redirUrl = UI_BROWSER.'?act=editItem&id='.$formdata['id'];
$this->_retMsg('Webstream metadata has been saved.'); $this->_retMsg('Webstream metadata has been updated.');
return TRUE; return TRUE;
} // fn editWebstream } // fn editWebstream
@ -350,7 +352,7 @@ class uiHandler extends uiBase {
} }
} }
$this->_retMsg('Audioclip metadata has been saved.'); $this->_retMsg('Audioclip metadata has been updated.');
} // fn editMetadata } // fn editMetadata
@ -648,7 +650,7 @@ class uiHandler extends uiBase {
if (function_exists("getimagesize")) { if (function_exists("getimagesize")) {
$size = @getimagesize($filePath); $size = @getimagesize($filePath);
if ($size === FALSE) { if ($size === FALSE) {
$this->_retMsg('Error while uploading logo: the file uploaded is not an image.'); $this->_retMsg('Error while uploading logo: not an supported image format.');
return FALSE; return FALSE;
} }
if ( ($size[0] > 128) || ($size[1] > 128) ) { if ( ($size[0] > 128) || ($size[1] > 128) ) {