pneudralics Posted April 20, 2009 Share Posted April 20, 2009 I want to save this to the database. After uploading the image and creating a new name for it I want to put it into $code before saving it into the database: $code = " <style type=\"text/css\"> body { background-image:url('urlgoeshere$newname'); } </style> "; The issue is it won't work if it's inside the if (isset). It seems like I need a way to get the newname from the uploading and add outside if the if(isset). Quote Link to comment https://forums.phpfreaks.com/topic/154892-solved-how-do-i-put-a-new-image-name-from-uploading-into-a-variable-with-css-codes/ Share on other sites More sharing options...
soak Posted April 20, 2009 Share Posted April 20, 2009 Could you give a bit more info please and try reading your question to ensure it makes sense before you click submit. Quote Link to comment https://forums.phpfreaks.com/topic/154892-solved-how-do-i-put-a-new-image-name-from-uploading-into-a-variable-with-css-codes/#findComment-814680 Share on other sites More sharing options...
pneudralics Posted April 20, 2009 Author Share Posted April 20, 2009 Nevermind I figured I'll just display the css with the new image name on a php page instead. thanks. Quote Link to comment https://forums.phpfreaks.com/topic/154892-solved-how-do-i-put-a-new-image-name-from-uploading-into-a-variable-with-css-codes/#findComment-814685 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.