Store database value in variable using php

Botoho

For example. I have a select statement that is "select ID from students where student name ='name';"

Now I don't wanna echo the student ID but I wanna store it in various where I can reuse it. How do I do it.

54 Views
About the Author
"select ID from students where student name ='name';"
Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.