yoded Posted December 11, 2009 Share Posted December 11, 2009 Hi,Storyline: I'm attempting to make something wich will allow visitors on my site to add certain new functions to a game, and in doeing so update a formula to calculate a certain variable wich is directly affected by the newly added function.Problem: In retrieving the formula from the MySQL database the server does not calculate the given formula into a variabele but simply outputs the text.Any help on how to overcome this problem? Link to comment Share on other sites More sharing options...
justsomeguy Posted December 11, 2009 Share Posted December 11, 2009 You can use eval to execute a string as a line of code. You need to watch out if you let people write PHP code, it's extremely easy to hack that and extremely difficult to prevent hacking. Link to comment Share on other sites More sharing options...
yoded Posted December 11, 2009 Author Share Posted December 11, 2009 thanks for the help, I already found a workaround for this problem but the info will come in handy either way.It's more of an admin panel than an open acces panel for users atm but thanks for the warning! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.