Menu Question

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
Smackie
Forum Contributor
Posts: 302
Joined: Sat Jan 29, 2005 2:33 pm

Menu Question

Post by Smackie »

ok im making a install script and was wondering if someone could tell me how to make it where they are on table 1 ok it would look like this

Table1
Table2


and if they are on Table2 it would be

Table1
Table2
Table3

how would i do it that way??


Thank you
Smackie
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Sorry, but your question doesn't make any sense. Could you elaborate?
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Smackie
Forum Contributor
Posts: 302
Joined: Sat Jan 29, 2005 2:33 pm

Post by Smackie »

I want it where they cant skip ahead and screw up somewhere i want it where they have to go in order.. i dont really know how to put it that way :? a friend told me to use like i think he said a if statement or something like that..
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

I/we are going to need to see some code before any help comes. You'll notice on this forum that people are very unlikely to help if they can't see you've tried to help yourself first.

Edit: Sorry, wrong thread. This was meant for another thread.

Anyway, I find your description very hard to understand. Could you be more clear?
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Smackie
Forum Contributor
Posts: 302
Joined: Sat Jan 29, 2005 2:33 pm

Post by Smackie »

first off i asked if someone could help me know how to do that code (so that means i dont know how to do that part of the scripting)...

but here is the part im trying to do the script on..


Code: Select all

<?php ob_start() ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Install</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
a:link {
	color: #00FFFF;
}
a:visited {
	color: #00CCFF;
}
a:hover {
	color: #FF0000;
}
a:active {
	color: #FFFF00;
}
-->
</style>
<script language="javascript">
function checkAll(){
for (var i=0;i<document.forms[0].elements.length;i++)
{
var e=document.forms[0].elements[i];
if ((e.name != 'allbox') && (e.type=='checkbox'))
{
e.checked=document.forms[0].allbox.checked;
}
}
}
</script>
</head>

<body bgcolor="White">
<table width="753" border="0" align="center" cellpadding="3" cellspacing="3">
  <tr> 
    <td height="25" colspan="2" valign="top">&nbsp;</td>
  </tr>
  <tr>
    <td width="135" height="27" valign="top"> <table align="center" width="135" border="1" bordercolor="#3399cc" cellspacing="1" cellpadding="1" valign="top">
        <tr> 
          <td width="513" height="20" valign="center" bgcolor=#336699><div align="center"><font color="#000000" size="2" face="verdana">NAVIGATION</font></div></td>
        </tr>
        <tr> 
          <td valign="top"><div align="center"> 
              <a class="three" href="install.php?pages=welcome">Welcome</a><br><br>

                                                <a class="three" href="install.php?pages=terms">Terms</a><br><br>

			  <a class="three" href="install.php?pages=tables1">Site Tables</a><br><br>
			  <a class="three" href="install.php?pages=tables2">Users Tables</a><br><br>
			  <a class="three" href="install.php?pages=tables3">PM Tables</a><br><br>
			  <a class="three" href="install.php?pages=tables4">Links Tables</a><br><br>
			  <a class="three" href="install.php?pages=tables5">News Tables</a><br><br>
			  <a class="three" href="install.php?pages=tables6">Shout Tables</a><br><br>
            
			  <a class="three" href="install.php?pages=site-stuff">Site Setup</a><br><br>

              <a class="three" href="install.php?pages=admin-stuff">Admin Signup</a><br><br>
              
			  <a class="three" href="install.php?pages=thanx">Thank You</a><br><br>
              
            </div></td>
        </tr>
      </table>
      <br>
    </td>
    <td width="598" valign="top"><table width="100%" border="1" cellpadding="0" cellspacing="1" bordercolor="#3399cc">
        <tr>
          <td>
and like i said i want it where the links are hidden expect when they first get on this the Welcome, and Terms links are showing... when they click terms then the Site Tables are set up the so on and so on.....
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

I wrote:I/we are going to need to see some code before any help comes. You'll notice on this forum that people are very unlikely to help if they can't see you've tried to help yourself first.
That comment was meant for another thread, not this one. Please ignore it, and I apologize if it offended you.



Anyway, are you trying to have the menu structure be different depending on what page the person is actually viewing? Sorry if I keep asking the same question, but I find it difficult to read your run-on sentences (hard to know where one idea ends and the other begins).
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
Smackie
Forum Contributor
Posts: 302
Joined: Sat Jan 29, 2005 2:33 pm

Post by Smackie »

Im trying to make it where they cant skip to the bottom of the menu so they can work there way up... or what ever.. I want it where they can only see the links that they already seen and the next one and the one they are installing..
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Sorry, one more time - What links do you want them to be able to see? Could you please go step by step through what you'd like a user's experience to be? Thanks.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
aybra
Forum Commoner
Posts: 56
Joined: Sun Nov 24, 2002 12:52 am

my two cents.

Post by aybra »

Honestly i would remove the option completly, make the script so it auto jumps forward, and if they at any time exit the script before it is done running, clear out the contents.


you can leave them seeing what has been done, and whats next. But not allow them to push any buttons, other than the "submit" button for what ever information you need.
I appoligize but it would take me some time, and some more intimate knowledge of what exactly your trying to do.. would be great if you posted a link to the live site that you are using. Let us run the installer and see what it does now, than we could better assist you in how to set it to do what you wanted.




***Examples of what i was saying.

on part one, it installs what you want it to do. You have a button that says continue, which has a value of "2".

at the top of your script you have a line that says.

Code: Select all

if($foo = 2){
do $install2;
}
then you would make your $install2 function run, and the button would have a value of "3", and the loop would go till the script is done to which it would say.

Conga Ratz!!! you installed my new dandy script!!!

keep in mind that code snippet isnt exact, and you should check out http://www.php.net. Which is a wonderful site for learning to code very basic.
Smackie
Forum Contributor
Posts: 302
Joined: Sat Jan 29, 2005 2:33 pm

Post by Smackie »

That is you i want my script like it is just i want the uses to see what has been done and the one they are on and the next one..
Post Reply