Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up

What is the difference between == and === in PHP?

  1. A === compares value and type; == coerces types before comparing
  2. B == compares references
  3. C === only works on integers
  4. D They are identical
Answer

=== compares value and type; == coerces types before comparing

Loose comparison against user input has caused real authentication bypasses. Use === by default and hash_equals for tokens.

All Php MCQs

Login to manage your account

Please enter a valid email address.
Forgot Password?
Please enter a valid password.
OR

Don't have an account yet? Sign up as