Preserved Topic: limit number of display (Page 1 of 1) |
|
---|---|
Paranoid (IV) Inmate From: Earth |
posted 03-16-2001 06:10
ok here is my scenario - I have a dir that has about 30 or so text files. I can already read out the contents of these files and display them on a page. But what I want to do is to be able to limit the display to like five at a time and then throw like a 'next' link at the bottom that displays the next five or so . . . does anyone have an idea how I can accomplish this? |
Maniac (V) Mad Scientist From: Belgrade, Serbia |
posted 03-16-2001 06:52 |
Paranoid (IV) Inmate From: Earth |
posted 03-16-2001 17:13
I'm sorry, PHP. |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 03-16-2001 19:10
Here's one way |
Paranoid (IV) Inmate From: Earth |
posted 03-16-2001 19:29
thanks bitdamaged but I think I need to clarify what I'm trying to do better. Ok I can go into the dir and display the dir listings 5 at a time, but where I'm stuck is to be able to then read out the contents of those 5 files. Like right now I'm using this: |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 03-16-2001 20:27
What I would do (there may be an easier way too) Is instead of using the implode, use a foreach loop (or "for" loop if you are not using PHP4) |
Paranoid (IV) Inmate From: Earth |
posted 03-18-2001 04:48
yeah, but that's just another way of writing what I had already had, so that won't do what I'm looking for. I guess want I should be doing is grab $parray (since it contains the 5 file that I want at the moment) loop through that and then try to read the file contents out. I don't know if that would exactly do it . . .someone please correct me if I'm wrong. |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 03-19-2001 05:36
No the include will print the files similar to an SSI call. |