Risks of using PHP eval [duplicate]
问题 This question already has answers here : Closed 8 years ago . Possible Duplicates: When (if ever) is eval NOT evil? when is eval evil in php? Since I found no other way of executing a string from an external file as code, I resorted to utilizing eval(). I am not asking about any code in particular, since examples in my use-case scenario would be trivial - what I want to know is what are the dangers of using eval in php code. I did some research on the subject, but I couldn't find any answer