My favorites
|
Sign in
rothui
Rothars World of Warcraft Interface
Project Home
Downloads
Source
Checkout
|
Browse
|
Changes
|
r498
Source path:
svn
/
trunk
/
php_ajax_armory_tutorial
/
armory.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
function getAjax(aserver,gserver,char,targetbox,lang) {
document.getElementById(targetbox).innerHTML = "Searching...";
var url = "get_char_data_xml.php?lang=" + lang + "&char=" + char + "&gserver=" + gserver + "&aserver=" + aserver;
retrieveURL(url,targetbox);
}
function retrieveURL(myurl,mytarget)
{
var container;
//alert(myurl);
if (mytarget) {
container = document.getElementById(mytarget);
} else {
container = document.getElementById("ajaxtargetbox");
}
//alert(container);
var request = false;
if (window.XMLHttpRequest)
{
request = new XMLHttpRequest();
}
else if (window.ActiveXObject)
{
try {
request = new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
try
{
request = new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e) {}
}
}
request.open("GET", myurl, true);
request.onreadystatechange = function()
{
if (request.readyState == 4)
{
container.innerHTML = request.responseText;
}
}
request.send(null);
}
Show details
Hide details
Change log
r428
by erik.raetz on Jul 15, 2009
Diff
[No log message]
Go to:
/trunk/php_ajax_armory_tutorial
...p_ajax_armory_tutorial/armory.js
...y_tutorial/get_char_data_xml.php
...y_tutorial/get_char_data_xml.txt
...x_armory_tutorial/guild_data.php
...x_armory_tutorial/guild_data.txt
Older revisions
All revisions of this file
File info
Size: 1186 bytes, 46 lines
View raw file
Hosted by