|
Posted by "Richard Lynch" on 10/03/24 11:16
On Wed, May 18, 2005 6:25 am, Michael Satterwhite said:
> I have a site that extracts HTML page code from a database and prints it
> to the page being generated. A user has requested that I allow this text
> to be dynamic. I can code process functions for the code that I pull
> from the database, but it would be so much better if I could simply get
> PHP to process the text for me.
>
> Does anyone know a way to cause this to happen?
Yes, but...
If you mean you want to allow your users to write PHP code in their HTML,
and have your script execute that PHP code, then you want:
http://php.net/eval
Buuuuuuuuuuuuut
This would be incredibly dangerous unless you REALLY REALLY REALLY trust
ALL your users. They could do some really nasty things with PHP if you let
them.
Tell us more about the data and the user and what you really want -- We
might have a safer answer for you...
One simple one might be to allow them to give you a URL where you will get
the text, and then you get their current text, instead of whatever is in
your databsae.
--
Like Music?
http://l-i-e.com/artists.htm
Navigation:
[Reply to this message]
|