-
Notifications
You must be signed in to change notification settings - Fork 9
/
template-edit.js
48 lines (46 loc) · 1.05 KB
/
template-edit.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
function select_mod(CODE)
{
var selectmod;
var TTYPE = "TYPE=";
var AAND = "&";
var MOD = "MODALITY=";
var REFERRER = document.template.modality.value;
var cat = document.getElementById('modality');
var TYPE = cat.options[cat.selectedIndex].value;
try
{
// Firefox, Opera 8.0+, Safari
selectmod=new XMLHttpRequest();
}
catch (e)
{
// Internet Explorer
try
{
selectmod=new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
try
{
selectmod=new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e)
{
alert("Your browser does not support AJAX!");
return false;
}
}
}
selectmod.onreadystatechange=function()
{
if(selectmod.readyState==4)
{
var resultarea = document.getElementById('showprocedure');
resultarea.innerHTML = selectmod.responseText;
}
}
//req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded;charset=tis-620"); // set Header
selectmod.open("GET","template-edit2.php?"+MOD+TYPE+AAND+Math.random(),true);
selectmod.send(null);
}