Today's Posts Follow Us On Twitter! TFL Members on Twitter  
Forum search: Advanced Search  
Navigation
Marketplace
  Members Login:
Lost password?
  Forum Statistics:
Forum Members: 24,254
Total Threads: 80,792
Total Posts: 566,471
There are 943 users currently browsing (tf).
 
  Our Partners:
 
  TalkFreelance     Design and Development     Programming     Other Programming Languages :

xmlHttp Problems & ASP

Thread title: xmlHttp Problems & ASP
     
    Thread tools Search this thread Display Modes  
Prev Previous Post   Next Post Next
03-01-2008, 06:03 PM
#1
Seraskier is offline Seraskier
Status: I love this place
Join date: Jan 2007
Location: Charlotte
Expertise:
Software:
 
Posts: 542
iTrader: 0 / 0%
 

Seraskier is an unknown quantity at this point

Send a message via AIM to Seraskier Send a message via MSN to Seraskier

  Old  xmlHttp Problems & ASP

Hello,

I do not code in asp, but I am wanting to use it because if I use php pages for my database additions, users can run the file and do basically whatever they want....

I have this code as testing but it doesnt seem to be working...

seems to be as simple as could be, but i dont know what could be the problem.. also im going to expand it more to do what i need...
(been coding in VB.net so im kinda rusty on php, javascript; give me a break please)

index.php
Code:
<script type="text/javascript" src="username.js"></script> 

<form> 
<input type="text" onKeyUp="checkUsername(this.value)">&nbsp;
<span id="response" style="font-size:10px; font-weight:bold"></span>
</form>
username.js
Code:
function checkUsername(str)
{	
	var url = "username.asp";
		url = url + "?username=" + str;
	xmlHttp.onReadyStateChange = stateChanged;
	xmlHttp.Open("GET", url, true);
	xmlHttp.Send(null);
}

function stateChanged() 
{ 
	if (xmlHttp.readyState == 4  && xml.Status == 200)
	{ 
		document.getElementById("response").innerHTML = xmlHttp.responseText;
	}
}
username.asp
Code:
<%
username = request.QueryString("username")

response.Write(username)
%>

hmm.. help please?

Sincerely,
Jordan | Seraskier

     


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

  Posting Rules  
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump:
 
  Contains New Posts Forum Contains New Posts   Contains No New Posts Forum Contains No New Posts   A Closed Forum Forum is Closed