The script to connect to the database works fine, as if i change the host, it gives me an error.
But im not getting any images from the database
What im trying to do is, randomly select any field and link the add field using the link field, so if a user clicks the add shown, it will take them to the website address in the link field.
Im also not sure how to add the title, so when a user hovers over the add shown, it will show a title tag ???
Can someone provide any helpful guidance to help me learn more coding skills.
The query searches the db randomly selects one add and displays it
What you provided gave an error !!
I tried $title which worked, but im not getting the add to show as its in a java script format as shown below
*****************************************
*********************************************************
im trying to rotate my adds from tradedoubler but im not sure if its possible to display java script correctly from a mysql db ??
you had syntax error on your query
SELECT * FROM table ORDER BY RAND(), LIMIT 1
erase the comma next to RAND(), it should look something like thisSELECT * FROM table ORDER BY RAND() LIMIT 1