Jump to content

Archived

This topic is now archived and is closed to further replies.

just-j

who do i read a paticular line from text??

Recommended Posts

ive searched for about 30 minutes on google and cant figure out how to read a line from text..  say i want to set line 15 from textfile.txt to a variable?  i did a foreach ($lines as $line_num => $line) loop to read the entire file line by line but i am making a table for the text that it reads and in order for it to work, i need to read the line after the one the foreach loop is on, in order to set the rowspan of the table.

Share this post


Link to post
Share on other sites
[quote]i need to read the line after the one the foreach loop is on[/quote]
Then iterate to the next line.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.