Page 1 of 1

Storing navigator information?

Posted: Wed Jul 06, 2005 10:25 am
by GyroVorbis
Hey, I'm a complete newbie at PHP. I picked up a book a couple of days ago, because I'm in desperate need of a finished site.

I'm a C/++ programmer, but I'm not experienced at a higher-level language such as PHP.

The first thing that I've decided needs to be done, is make a navigator that every page loads. I want to make it easy to manage and edit. Also, I've decided that the site will be based on flat text file storage, because I don't think databases will be necessary for the things I'm going to be doing, and I don't have time to learn to use them.

There are 3 things that I need to store. 1) the main headings 2) the titles of the links under them 3) the actual URL the links.

http://thechaosrift.com/template.htm The navigator panel on the left is what I'm refering to.

Is there any format you guys would recommend I store this in with text files so that they can easily be extracted and put into place when the site loads from the navigator?

Should I use multiple text files?

Any help or advice is much appreciated.

Posted: Wed Jul 06, 2005 10:42 am
by Burrito
if just creating the navigation you are, put them in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\&quote;page1.php\&quote;&gt;page1&lt;/a>";
//etc
necessary to "store" information about those links it is not unless collecp;amp;lt;/a>";
//etc


necessary to "store" information about those links it is not unless collecting data about # of times;quote;nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1&lt;/a&gt;&quote;;
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";he navigation you are, put them in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">paghe navigation you are, put them in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>&am]
include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.quote;nav.inc.php");

Code: Select all

echo &quote;&lt;a href=\&quote;page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc youare, put them in a separate "included" php file I would.

ie:

Code: Select all

include(&quote;nav.inc.php&quote;);

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.cessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.te "included" php file I would.

ie:

Code: Select all

include(&quote;nav.inc.php&quote;);

Code: Select all

echo &quote;&lt;a href=\&quote;page1.php\&quote;&gt;page1&lt;/a&gt;&quote;;
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.//etc


necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.mp;quote;);

Code: Select all

echo "<a href=\"page1.php\&quote;& I would.

ie:

Code: Select all

include("nav.inc.php&quote;);

Code: Select all

echo &quote;&lt;a href=\&quote;page1.php\&quote;&gt;page1&lt;/a&gt;&quote;he navigation you are, put them in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are. php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\&quote;page1.php\&quote;&gt;page1&lt;/a&gt;&quote;;
//etc
necessary to "store" information about those links it is not unless collecting data about uote;<a href=\"page1.php\">page1</a>";
//etc


necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.he navigation you are, put them in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.em in a separate "included" php file I would.

ie:

Code: Select all

include("nav.inc.php");

Code: Select all

echo &quote;&lt;a href=\&quote;page1.php\&quote;&gt;page1&lt;/a&gt;&quote;;
//etc
necessa6f1fce477]
include("nav.inc.php");

Code: Select all

echo "<a href=\&quote;page1.php\&quote;&gt;page1&lt;/a&gt;&quote;;
//etc

include("nav.inc.php");

Code: Select all

echo "<a href=\"page1.php\">page1</a>";
//etc
necessary to "store" information about those links it is not unless collecting data about # of times hit etc you are.