diff --git a/program/js/app.js b/program/js/app.js
index 72b6903e8..4407bc719 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -4938,7 +4938,7 @@ function rcube_webmail()
if (!attachment)
return;
- var input = $('').attr('type', 'text').val(attachment.name),
+ var input = $('').attr({type: 'text', size: 50}).val(attachment.name),
content = $('