PHP thinks you're using the string 'id' whereas you need it to be a variable. You need something like
$sql = "SELECT ID,NAAM,CONTACT FROM table WHERE ID = " . $_GET['id'];
Note there is no comma following the name of last column listed in the SELECT. In addition, you don't need to use backticks with table or column names in SQL statements unless they contain special characters.
Also, you should make sure that you always use the same lettercase for your table columns as you did in the CREATE TABLE statement that created the table. If your table column is named
id, then trying to reference the column as
ID or
Id is not going to work. The usual convention is to use lowercase for table and column names, but it doesn't really matter as long as you're consistent about it and you use exactly the same lettercase for these in your queries.
Good luck!
Jon Stephens
MySQL Documentation Team @ Oracle
MySQL Dev Zone
MySQL Server Documentation
Oracle