Changeset 4457 for sandbox/2.2.0.2/expressoMail1_2/js/common_functions.js
- Timestamp:
- 05/19/11 13:38:13 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/2.2.0.2/expressoMail1_2/js/common_functions.js
r4416 r4457 342 342 var countDivFiles = 1; 343 343 344 divFile = document.createElement('div'); 345 346 var inputFile = document.createElement("input"); 344 divFile = document.createElement('div'); 345 var inputFile = document.createElement("input"); 347 346 inputFile.id = "inputFile_"+id_border+"_"+countDivFiles; 347 348 348 inputFile.name = "file_"+countDivFiles; 349 349 inputFile.type = "file"; 350 inputFile.size = 50; 351 inputFile.maxlength = 255; 352 inputFile.onchange = function () { 353 validateFileExtension(this.value, this.id.replace('input','div'), this.getAttribute('id_border')); 354 openTab.autosave_timer[id_border] = setTimeout("save_msg("+id_border+")", autosave_time); 350 inputFile.size = 50; 351 inputFile.maxlength = 255; 352 353 inputFile.onchange = function () { 354 validateFileExtension(this.value, this.id.replace('input','div'), this.getAttribute('id_border')); 355 356 openTab.autosave_timer[id_border] = setTimeout("save_msg("+id_border+")", autosave_time); 355 357 }; 356 357 inputFile.onfocus = function () { 358 if (openTab.autosave_timer[id_border]) 359 clearTimeout(openTab.autosave_timer[id_border]); 360 }; 361 362 divFile.appendChild(inputFile); 363 364 var linkFile = document.createElement("a"); 365 linkFile.id = "linkFile_"+id_border+"_"+countDivFiles; 366 linkFile.href = 'javascript:void(0)'; 367 linkFile.onclick = function () {removeFile("divFile_"+id_border+"_"+countDivFiles); return false;}; 368 linkFile.innerHTML = get_lang("Remove"); 369 358 359 360 inputFile.onfocus = function () { 361 if (openTab.autosave_timer[id_border]) 362 clearTimeout(openTab.autosave_timer[id_border]); 363 }; 364 365 divFile.appendChild(inputFile); 366 var linkFile = document.createElement("a"); 367 linkFile.id = "linkFile_"+id_border+"_"+countDivFiles; 368 linkFile.href = 'javascript:void(0)'; 369 linkFile.onclick = function () { 370 removeFile("divFile_"+id_border+"_"+countDivFiles); return false; 371 }; 372 373 linkFile.innerHTML = get_lang("Remove"); 374 370 375 divFile.appendChild(linkFile); 371 376 divFile.id = "divFile_"+id_border+"_"+countDivFiles; … … 376 381 // Remove Input File Dynamically. 377 382 function removeFile(id){ 378 var border_id = id.substr(8,1);379 383 var el = Element(id); 380 384 el.parentNode.removeChild(el); … … 565 569 566 570 if ((!data.status) && (data.error == "many results")){ 567 alert(get_lang('More than %1 results. Please, try to refine your search.', 200));571 alert(get_lang('More than %1 results. Please, try to refine your search.',data.maxResult)); 568 572 return false; 569 573 }
Note: See TracChangeset
for help on using the changeset viewer.