I'd like to create an array of "available resources", and be able to
check it every time. What I'd like to do is something like;
$site = array( "section1" => #, "section2" => #, etc.. )
where "section*" is a STRING variable and # is an INT (if it's even
possible to do that)
Once I have this setup properly, I'm going to have a routine that
extracts data from PATH_INFO, namely '$section' and '$page' which should
then be checked against the array:
- if $section exists in the array
- if $page is less or equal to the INT value in that $section
do something with $page (or just break out of the routine)
- else
default to 1 (and break out)
- else
default to something like main, or whatever, and set $page to 1
These values will then be used in a template to read in the proper
files through <? include $section$page."inc"; ?>
I don't know whether I can create an array of STR => INT values, and
I don't know where to start with the function needed to traverse that
array once I have information from PATH_INFO (of course, this is
depending on PATH_INFO even passing along valid information)
--
H | "Life is the art of drawing without an eraser." - John Gardner
+--------------------------------------------------------------------
Ashley M. Kirchner <mailto:[EMAIL PROTECTED]> . 303.442.6410 x130
Director of Internet Operations / SysAdmin . 800.441.3873 x130
Photo Craft Laboratories, Inc. . 3550 Arapahoe Ave, #6
http://www.pcraft.com ..... . . . Boulder, CO 80303, U.S.A.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]