[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Loop through a string "lines" at a time
- From: Shmuel Zeigerman <shmuz@...>
- Date: Tue, 03 Jul 2007 14:01:35 +0200
RJP Computing wrote:
Is there a way to loop through a string "lines" at a time? Kind of like
file:lines(). I am very new to the string library in Lua and I can't get
what I want out of the string.
With Lrexlib, it's done as follows:
for line in rex.split(text, "\n") do
-- do something with line
end
--
Shmuel