Saving a Variable in DB
Posted: Thu Apr 30, 2009 1:33 pm
I am working on a content editor for a website and I would like to allow the admin to put in variables(the currently logged in user's username) into the page content. How would I go about doing this so that it echos the username instead of $username?
I have attempted to use eval but it doesn't seem to work with html tags. I have also tryed to serialize the variable but when I go to echo the unserialized version, it doesn't echo anything. Any ideas?
I have attempted to use eval but it doesn't seem to work with html tags. I have also tryed to serialize the variable but when I go to echo the unserialized version, it doesn't echo anything. Any ideas?