[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Reading a conf file
- From: Valentin <vsl@...>
- Date: Thu, 29 Sep 2016 17:26:41 +0200
Russell Haley wrote:
> Hi Valentin,
>
> I was unable to make this work at all. I kept getting "attempt to call
> a nil value (global 'loadstring')" which PIL online tells me is normal
> for a syntax error.
Hi Russel,
I should have mentioned that my code was meant for Lua 5.1. In Lua 5.1.
it works perfectly with your sample conf file (an no, the extra ","
doesn't hurt and doesn't need to be removed).
For Lua 5.2 and Lua 5.3. you simply have to replace 'loadstring' with
'load'.
Cheers,
Valentin