11-27-2014, 03:04 AM
(This post was last modified: 11-27-2014, 03:13 AM by nouseforname.)
(11-27-2014, 02:56 AM)xoft Wrote: Try to use the "local" keyword as much as possible - variables in Lua are global by default, and you don't want your variables from one function overwritten with variables from another function.i know this and try it already as i don't like global vars. But thanks for the hint I know i forgot one "local" in the above sample.
Quote:Also don't forget to use SQL placeholders, as this will decrease the possibility of an SQL injection attack.Yes you are right, but i think i do it bit different way, so nothing strange should happen. We will see. Anyway, when i am done i will post it and ask for some imrovement suggestions as i am new to lua. Even i know quite a few other programming/scripting languages i guess it could be improved
Edit:
Also its not possible to set the name with spaces inside, due to the args are splitted by whitespace even if you use quotation marks