Wednesday, 4 September 2013

Pass PHP value to JQuery

Pass PHP value to JQuery

I do have a file called userAuthentication.php with a function that
returns a Boolean, if the authentication is successful sends "true"
otherwise "false".
I also have a view called login.html, with username and password input and
the corresponding submit button.
All works well, now I am wondering how could I present a message on the
login.html view maybe using JS or JQuery when the function returns
"false", i.e. authentication failure.
I have been going through three PHP value pass to jQuery & jquery -
passing value to php.
I am looking for the best way to do it, so I could use the same method for
any other implementation.
Thanks in advance,

No comments:

Post a Comment