version 1.3, 2019/08/11 14:16:55
|
version 1.4, 2023/07/11 22:24:30
|
Line 105 INPUT:
|
Line 105 INPUT:
|
|
|
The PREFIX is empty unless the resource is within a composite page. |
The PREFIX is empty unless the resource is within a composite page. |
|
|
|
For upload to "IMS upload" in Main Content or "Upload File" in |
|
Supplemental Content in the Course Editor, the SUFFIX is extracted |
|
from the id of the file upload element, by splitting the id on |
|
underscore, and using the second element. |
|
|
*/ |
*/ |
function getMaxSize (fileInput,sizeItem) { |
function getMaxSize (fileInput,sizeItem) { |
var maxSize = 0; |
var maxSize = 0; |
Line 118 function getMaxSize (fileInput,sizeItem)
|
Line 123 function getMaxSize (fileInput,sizeItem)
|
if (found.length == 3) { |
if (found.length == 3) { |
sizeId = found[1]+sizeItem+'_'+found[2]; |
sizeId = found[1]+sizeItem+'_'+found[2]; |
} |
} |
|
} else if ($(fileInput).hasClass("LC_uploaddoc")) { |
|
uploadId = $(fileInput).attr('id'); |
|
var re = /^uploaddoc(.+)$/; |
|
var found = uploadId.match(re); |
|
if (found.length == 2) { |
|
sizeId = sizeItem+'_'+found[1]; |
|
} |
} |
} |
if ( $("#"+sizeId).length) { |
if ( $("#"+sizeId).length) { |
if ( $("#"+sizeId).val() > 0) { |
if ( $("#"+sizeId).val() > 0) { |