a little help with php nav

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
redfire
Forum Newbie
Posts: 2
Joined: Tue Jun 03, 2003 10:25 pm
Location: London On Canada
Contact:

a little help with php nav

Post by redfire »

let me explain what i am trying to do, I have a list of links down the left side of my page. and when I go to a section say counter-strike I want it to load the cs nav "cs.php" so I got it doing that
with this code here.

<?php

if ($page=="cs-home") {
include ("http://www.themobnetwork.com/site/nav/cs.php");
}

elseif ($page=="d2-home") {
include ("http://www.themobnetwork.com/site/nav/d2.php");
}

elseif ($page=="") {
include ("http://www.themobnetwork.com/site/nav/nav.php");
}

else {
include ("http://www.themobnetwork.com/site/nav/nav.php");
}

?>

Now I want it to that the cs nav will load with every cs page so cs-home, cs- roster etc now I was thinking somthing like if ($page=="cs-*") but I am still fairly noob with php and learning. so if anyone could help me out. that would be amazing..

thank you ahead of time
User avatar
nigma
DevNet Resident
Posts: 1094
Joined: Sat Jan 25, 2003 1:49 am

Post by nigma »

Nigma to the rescue! Hey, I would be interested in working on this with you. I am almost certain I could help if things were clerified a bit. It alright if I add you to like YIM or MSN(whichever you prefer) and we talk about this some more?
redfire
Forum Newbie
Posts: 2
Joined: Tue Jun 03, 2003 10:25 pm
Location: London On Canada
Contact:

Post by redfire »

ok that would be great, add me to msn, bigdrakar@hotmail.com I don't realy use icq or yahoo anymore, but if thats all u have I will boot up the old gal again.

thank you for all your help
Post Reply