http://lua-users.org/wiki/PatternsTutorial
In the 'Captures' section is this code...
date = "04/19/64"
m, d, y = string.match(date, "(%d+)/(%d+)/(%d+)")
print(m)
print(d)
print(y)it works fine with the contents of 'date' and returns:
4
19
64
Yet if I try to pass it a json string such as this...
"sun_phase": {
"sunrise": {
"hour":"6",
"minute":"49"
},
"sunset": {
"hour":"17",
"minute":"34"
}I get...
nil
nil
nil
Anybody know why please?