Reply to Re: executing PHP code from db?

Your name:

Reply:


Posted by Peter Wilson on 06/19/05 17:10

In article <42b54c55$0$21663$e4fe514c@news.xs4all.nl>, Pr0 N00b
<nomail@mail.invalid> writes
>juglesh schreef:
>>
>> Pr0 N00b wrote:
>>
>>>mjamm schreef:
>>>
>>>>Hello
>>>>
>>>>Is there any way to execute PHP code from a database on to a .php browser
>>>>page?
>>>>
>>>>Basically, I am using 'LONGTEXT' to save HTML and other info to output to
>>>>the screen. Works well!
>>>>
>>>>I have tried saving something simple like <?php echo "HELLO!"; ?> to the db
>>>>and then calling it from the database, having the output perform the script
>>>>on to the screen.
>>>
>>>You should look at the eval() command. The only problem with it is that
>>>it doesn't like <?php and ?>, so your code would just be `echo "HELLO!";
>>
>>
>> 'less you go like this:
>> <?php
>> eval('?>' . $somethingsimple . '<?php ');
>> ?>
>
>W0W, never expected _that_ to work :-)

very nice but how do you get it to parse the code? there for executing
say the echo?


Peter
Motto "A smile aday keeps the blues away"

http://www.sci-comm.clara.net/

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация