Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Try out my first PHP web app! Reply To: Try out my first PHP web app!

#182221
__
Participant

And I’m still getting the same error as before.

Meaning, the “non-object” error?
Did you check $con->error for errors from the DB?

edit

if I comment out the prepare($query) line and do echo $pass; it echoes out the username I tried to log in with…

If you comment out $stmt = $con->prepare($query);, you should get an error similar to Notice: Undefined variable: stmt on the line after. Do you have error reporting configured to show all errors? or are you ignoring Notices?

Even if that error was not present, $pass would be undefined as well, unless you’re assigning it somewhere earlier in your code.