file count and file name functions

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
cczernia
Forum Newbie
Posts: 20
Joined: Tue May 16, 2006 2:00 pm
Location: San Diego, CA

file count and file name functions

Post by cczernia »

I'm trying to write a quick script that creates previous and next buttons. The easiest way I've found to do this is by numbering all the pages and having the previous and next buttons count by linking to the page number (+/-) 1. I've ran into two problems.

1. I need a way to know the total number of pages in the directory so when it gets to the last page it doesn't go to the last page +1.

2. I would like a way to make the file name a variable.



Also, if anyone has any tips on how to search functions to find what you are looking for I'd appreciate.

Thanks in advance.
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

Post Reply