|
|
|
@ -472,12 +472,16 @@ function urlencode(str)
|
|
|
|
|
function rcube_find_object(id, d)
|
|
|
|
|
{
|
|
|
|
|
var n, f, obj, e;
|
|
|
|
|
|
|
|
|
|
if (!d) d = document;
|
|
|
|
|
|
|
|
|
|
if(d.getElementsByName && (e = d.getElementsByName(id)))
|
|
|
|
|
if (d.getElementById)
|
|
|
|
|
if (obj = d.getElementById(id))
|
|
|
|
|
return obj;
|
|
|
|
|
|
|
|
|
|
if (!obj && d.getElementsByName && (e = d.getElementsByName(id)))
|
|
|
|
|
obj = e[0];
|
|
|
|
|
if(!obj && d.getElementById)
|
|
|
|
|
obj = d.getElementById(id);
|
|
|
|
|
|
|
|
|
|
if (!obj && d.all)
|
|
|
|
|
obj = d.all[id];
|
|
|
|
|
|
|
|
|
@ -494,7 +498,8 @@ function rcube_find_object(id, d)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (!obj && d.layers) {
|
|
|
|
|
if (d.layers[id]) obj = d.layers[id];
|
|
|
|
|
if (d.layers[id])
|
|
|
|
|
obj = d.layers[id];
|
|
|
|
|
for (n=0; !obj && n<d.layers.length; n++)
|
|
|
|
|
obj = rcube_find_object(id, d.layers[n].document);
|
|
|
|
|
}
|
|
|
|
|