This question is an exact duplicate of:
- How to get data from mysql database 3 answers
I got user
Table which contains fields like userName
,department
and so on. So My question is if login user belongs to Computer Sci & Technology department
then how do i select all the user who belongs to the Computer Sci & Technology department
from the database
userName courseID department
sachin 1 Civil Engineering
virat 2 Computer Sci & Technology
rohit 2 Computer Sci & Technology
<form role="form" method="post" action="user/checkLogin.php">
<input type="text" name="u_ID" value="" placeholder="Unique-ID">
<input type="password" name="dob" value="" placeholder="Birth Date (DD/MM/YY)"> </form>
so the result should be virat and rohit
</div>