i know this really is a lot to ask but i am really lost here and will appreciate any help anyone might be able to offer.
next, previous, and newest buttons
Moderator: General Moderators
-
insert_witty_name_here
- Forum Newbie
- Posts: 4
- Joined: Thu Feb 12, 2004 11:37 pm
next, previous, and newest buttons
i know this really is a lot to ask but i am really lost here and will appreciate any help anyone might be able to offer.
-
Illusionist
- Forum Regular
- Posts: 903
- Joined: Mon Jan 12, 2004 9:32 pm
-
insert_witty_name_here
- Forum Newbie
- Posts: 4
- Joined: Thu Feb 12, 2004 11:37 pm
RE:
yea i thought about just doing it in html, but every time i add a comic, then the "newest link" button on every page that it is on will have to be manually updated. with each comic its own page, which could quickly go into the hundreds of pages that i would have to change every time i added a comic.
what might make this a lot easier is if the names of the files were changed to the date they were posted (like 02/13/04.html). then the script would just look for the next date or the date before or the newest date
what might make this a lot easier is if the names of the files were changed to the date they were posted (like 02/13/04.html). then the script would just look for the next date or the date before or the newest date
- John Cartwright
- Site Admin
- Posts: 11470
- Joined: Tue Dec 23, 2003 2:10 am
- Location: Toronto
- Contact:
-
insert_witty_name_here
- Forum Newbie
- Posts: 4
- Joined: Thu Feb 12, 2004 11:37 pm
re
oh, well the 1-comic.html, 2-comic.html... would be what i was really looking for. if that could work then that would be great.
-
Illusionist
- Forum Regular
- Posts: 903
- Joined: Mon Jan 12, 2004 9:32 pm
-
spectre013
- Forum Newbie
- Posts: 5
- Joined: Wed Jul 09, 2003 9:09 am
- Location: Colorado, USA
I do some thing like this for our news paper. We name our file ni1.htm, ni2.htm for our news stories.
then we read the dir looking for files that start with ni count how many we have then loop through making the links like this.
Hope that made makes sense, if you need more code just let me know will help you out.
then we read the dir looking for files that start with ni count how many we have then loop through making the links like this.
Code: Select all
for($i=0; $i<$files; $i++)
{
echo "<a href="ni:.$i.".htm">Title</a>";
}-
Illusionist
- Forum Regular
- Posts: 903
- Joined: Mon Jan 12, 2004 9:32 pm