I'm starting to get desperate so I need help from other good PHP programmers.
I'm working on a registration page, which works except for this problem:
Registering an account into Account.dbo works, but then the code needs to fetch the AID from that table,
and register it into Login.dbo with that AID value.
The AID never gets caught, and using var_dump($aid), results in "NULL".
This is the code I'm using: (not the full code ofcourse).
If anyone has the answer, post it.Code:$selAcq = mssql_query("SELECT AID FROM Account WHERE UserID='$name'"); $aid = $selAcq['AID']; echo $aid; $inLog = "INSERT INTO Login(AID,UserId,Password,LastIP) VALUES('$aid','$name','$pass','$ip')"; mssql_query($inLog);


Reply With Quote


