lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

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