Posts: 3,621
Name: Thierry
Location: I'm the uber Spaminator !
|
I'm surprised that nobody told it sooner, but please, don't do that.
It's simply asking for troubles.
It's wastful on the resources. Each eval is like launching another PHP instance, with a new context, and context switching IS costly.
It's slow, because for each block of code, you have to make a call to the db. A db call (even for a small set of datas) is around 150 times slower than reading a file.
You will spend most of the time waiting for the db resultset and eval()'uating your content...
It's very, very difficult to debug and extremly prone to side effects.
If you are not very careful upon sql injection, it's a big door widely open, with tracking light and a flag saying "hackers welcome" and "please hit me real hard !"
__________________
Only a biker knows why a dog sticks his head out the window.
|