Ajaxで取得した値をreturnする
with文を使う
function getYM (url) { with (new XMLHttpRequest) { open ("GET", url, false); setRequestHeader ("If-Modified-Since", "01 Jan 2000 00:00:00 GMT"); send (null); return responseText; } } alert (getYM ('sql.txt'));
with文を使う
function getYM (url) { with (new XMLHttpRequest) { open ("GET", url, false); setRequestHeader ("If-Modified-Since", "01 Jan 2000 00:00:00 GMT"); send (null); return responseText; } } alert (getYM ('sql.txt'));