Hey!
Is there any way to use other functions as mysql_fetch_xxx for getting news from mysql db?
I have used echo mysql_result(mysql_query("SELECT title FROM news WHERE id = $_GET['id']"));
but function doesn't work at all.
Any alternatives?
Hey!
Is there any way to use other functions as mysql_fetch_xxx for getting news from mysql db?
I have used echo mysql_result(mysql_query("SELECT title FROM news WHERE id = $_GET['id']"));
but function doesn't work at all.
Any alternatives?
You are not using the functions correctly. Please refer to the official documentation of mysql_query. That page also has example code that shows you how to use the mysql-related functions.
Please, for the love of the internet, don't built an SQL query yourself. Use PDO.