2001-11-22 06:23:56 +00:00
|
|
|
|
|
|
|
<SCRIPT LANGUAGE="JavaScript">
|
|
|
|
<!-- //hide
|
2002-10-12 04:09:51 +00:00
|
|
|
|
|
|
|
function popUpProperties(inobj) {
|
|
|
|
op = window.open();
|
|
|
|
op.document.open('text/plain');
|
|
|
|
for (objprop in inobj) {
|
|
|
|
op.document.write(objprop + ' => ' + inobj[objprop] + '\n');
|
|
|
|
}
|
|
|
|
op.document.close();
|
|
|
|
}
|
|
|
|
|
2001-11-22 06:23:56 +00:00
|
|
|
function fillmessagebox(text) {
|
2002-10-12 04:09:51 +00:00
|
|
|
document.form.message.value = text;
|
2001-11-22 06:23:56 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
function openpopup(url,name,height,width) {
|
2002-10-12 04:09:51 +00:00
|
|
|
fullurl = "<?=$CFG->wwwroot ?>" + url;
|
|
|
|
options = "menubar=0,location=0,scrollbars,resizable,width="+width+",height="+height;
|
|
|
|
windowobj = window.open(fullurl,name, options);
|
|
|
|
windowobj.focus();
|
2002-10-10 07:26:10 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
function copyrichtext(textname) {
|
2002-10-12 04:09:51 +00:00
|
|
|
textname.value = document.richedit.docHtml;
|
|
|
|
return true;
|
2001-11-22 06:23:56 +00:00
|
|
|
}
|
|
|
|
|
2003-02-17 17:02:56 +00:00
|
|
|
function checkall() {
|
|
|
|
void(d=document);
|
|
|
|
void(el=d.getElementsByTagName('INPUT'));
|
|
|
|
for(i=0;i<el.length;i++)
|
|
|
|
void(el[i].checked=1)
|
|
|
|
}
|
|
|
|
|
2003-05-08 16:09:30 +00:00
|
|
|
function inserttext(text) {
|
|
|
|
<?PHP
|
|
|
|
if (!empty($SESSION->inserttextform)) {
|
|
|
|
$insertfield = "opener.document.forms['$SESSION->inserttextform'].$SESSION->inserttextfield";
|
|
|
|
} else {
|
|
|
|
$insertfield = "opener.document.forms['theform'].message";
|
|
|
|
}
|
|
|
|
echo " text = ' ' + text + ' ';\n";
|
|
|
|
echo " if ( $insertfield.createTextRange && $insertfield.caretPos) {\n";
|
|
|
|
echo " var caretPos = $insertfield.caretPos;\n";
|
|
|
|
echo " caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ? text + ' ' : text;\n";
|
|
|
|
echo " } else {\n";
|
|
|
|
echo " $insertfield.value += text;\n";
|
|
|
|
echo " }\n";
|
|
|
|
echo " $insertfield.focus();\n";
|
|
|
|
?>
|
|
|
|
}
|
|
|
|
|
|
|
|
<?PHP if ($focus) { echo "function setfocus() { document.$focus.focus() }\n"; } ?>
|
2001-11-22 06:23:56 +00:00
|
|
|
|
|
|
|
// done hiding -->
|
|
|
|
</SCRIPT>
|
|
|
|
|