Hi,
I have searched for this for a long time, but cannot find the answer... sorry if it's simple or is on here already, I did look!

Anyway - I'm trying to overlay text from a database on an image using php for use in banner ads for a client. So the add says, "I have earned code from database so far!"

I have got as far as laying the text on the image, and calling the text from the database works when the user is logged in, but when it's viewed remotely it just comes up with $hits instead...

Neo-bux do something something similar, if that helps: http://images.neobux.com/imagens/banner9/?u=dave086&u3=3934628 (not a plug - I don't use it! lol). I know this link uses URL rewrite, and I've got that sussed.

Anyone got any suggestions? I'm lost!

Code Using:
http://pastebin.com/E1mvmtrb
http://pastebin.com/SrHLbzPF

Shouldn't it be

$row = mysql_num_rows($result)

instead of

$row = mysql_fetch_array($result)

Shouldn't it be

$row = mysql_num_rows($result)

instead of

$row = mysql_fetch_array($result)

That is right, he is calling mysql_fetch_array twice which is wrong!

Be a part of the DaniWeb community

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