I am trying to assign a variable "$fullname" from database, and then output that variable text content to png. The $fullname script works if I echo it to the screen. And the text-to-png part works if I either manually declare the text to be transformed or if I manually declare the value of the $fullname variable (see commented test in code). But if I use two together to dynamically set the value of the $fullname variable, it does not work. Is there something glaring and obvious I am missing? I know the query is not pretty. The DB schema I am working with is ... bad. But it is what I have to work with right now. Here's my code: I was unable to post code, so check it here: [a href=\"http://bogobug.com/uname_to_png.txt\" target=\"_blank\"]http://bogobug.com/uname_to_png.txt[/a]