View Full Version : EXTjs success and waitMsg messages doubts...

18 Oct 2010, 10:34 AM
Hi everyone, what's up? I am facing a really big problem, I can't retrieve a success message to the user when
the upload is done, I don't know he only see the waitMsg look at below please ->

Document : popupWindow_importa_imagem.jsp
Created on : 15/10/2010
Author : André Asantos

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<link rel="stylesheet" type="text/css" href="js/ext-3.1/resources/css/ext-all.css"/>
<link rel="stylesheet" type="text/css" href="js/ext-3.1/plugins/fileuploadfield.css"/>

<script type="text/javascript" src="js/ext-3.1/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="js/ext-3.1/ext-all.js"></script>
<script type="text/javascript" src="js/ext-3.1/plugins/FileUploadField.js"></script>

<!-- Início da biblioteca awesomeuploader -->
<link rel="stylesheet" type="text/css" href="js/ext-3.1/plugins/awesomeuploader/Ext.ux.form.FileUploadField.css" />
<link rel="stylesheet" type="text/css" href="js/ext-3.1/plugins/awesomeuploader/AwesomeUploader.css" />

<script type="text/javascript" src="js/ext-3.1/plugins/awesomeuploader/Ext.ux.form.FileUploadField.js"></script>
<script type="text/javascript" src="js/ext-3.1/plugins/awesomeuploader/Ext.ux.XHRUpload.js"></script>
<script type="text/javascript" src="js/ext-3.1/plugins/awesomeuploader/swfupload.js"></script>
<script type="text/javascript" src="js/ext-3.1/plugins/awesomeuploader/swfupload.swfobject.js"></script>
<script type="text/javascript" src="js/ext-3.1/plugins/awesomeuploader/AwesomeUploader.js"></script>
<!-- Fim da biblioteca awesomeuploader -->

<script type="text/javascript">
Ext.onReady(function() {
var form1 = new Ext.FormPanel({
title: 'Upload de Fotos',
renderTo: 'div-form-1', //do HTML
width: 320,
buttonAlign: 'center',
frame: true,
fileUpload: true,
style: 'margin: 0 auto;',

items: [{
xtype: 'fileuploadfield',
emptyText: 'Selecione uma foto',
fieldLabel: ' Foto 1',
buttonText: 'Procurar',
name: 'imagemDoUsuario1',
id: 'form-file-1'
}, {
xtype: 'fileuploadfield',
emptyText: 'Selecione uma foto',
fieldLabel: ' Foto 2',
buttonText: 'Procurar',
name: 'imagemDoUsuario2',
id: 'form-file-2'
}, {
xtype: 'fileuploadfield',
emptyText: 'Selecione uma foto',
fieldLabel: ' Foto 3',
buttonText: 'Procurar',
name: 'imagemDoUsuario3',
id: 'form-file-3'

buttons: [{
text: 'Importar',
handler: function() {
url: 'fazerUploadDeImagem.action',
waitMsg: 'Importando sua(s) foto(s)...',
success: function(form, o) {
alert("Fotos importadas com sucesso");
}, {
text: 'Limpar',
handler: function() {


<style type="text/css">
#div-form-1 {
background: #e3e3e3;
padding: 20px;
margin: 20px;

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<div id="div-form-1"></div>

I thought EXTjs library was ready to detect if the photo were uploaded into database then send success message to user but it won't work.