|
Haven't registered yet? Do it here now!
|
juggernaut
Joined: 30 Aug 2005 Posts: 7
|
|
|
|
|
|
|
Posted: Tue Nov 07, 2006 5:29 pm Post subject: Kat need your php advice |
|
|
|
|
|
|
|
|
|
|
I'm wondering if I'm going about this the wrong way. I would like to have two tables on my index. Left table holds my navigation with a "require menu.php" and right table have the content be dynamic. I have another site that seems to do this but I did not code it so I'm unsure of what it's doing. The code reads on my site that does this as "include($file);"
I do not want to have to put the table and menu code on all the templates I created. I would perfer a surfer just click the nav on the left an the template content show up in the right side table. I'm not much of a coder but have done it long enough to be able to figure somethings out. Any help you can give me would be great cause I have been boiling my brain all morning. |
|
|
|
|
|
|
|
kaktus Owner
Joined: 22 May 2004 Posts: 1576 Location: CheapestAdultScripts.com
|
|
|
|
|
|
|
Posted: Wed Nov 08, 2006 1:55 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
make a page for example index.php
on left put include menu.php
and make the links in the navigation be like
index.php?niche1
index.php?niche2
.....
then on the right side, make a small script to do like
if(isset($niche1))
include niche1.php
elseif(isset($niche2)
include niche2.php
...
Hope this helps.. _________________
|
|
|
|
|
|
|
|
juggernaut
Joined: 30 Aug 2005 Posts: 7
|
|
|
|
|
|
|
Posted: Wed Nov 08, 2006 5:36 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
Cant get it to work. Where I am worng with this code? All I get is a blank page after I insert the script. I can get the menu to include and show up before I insert the script but after it's inserted I get blank..
Menu Code
------------
<body>
<a href="index.php?niche1">Amateur</a><br />
Anal<br />
------------------
Index code
------------------
</head>
<body><table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="30%" align="left" valign="top">
<?php include("menu.php"); ?>
</td>
<td width="80%" align="left" valign="top">
<?php if(isset($niche1)) include so/sohtml/amtmbs.php elseif(isset($niche2) include niche2.php ?>
</td>
</tr>
</table>
</body> |
|
|
|
|
|
|
|
kaktus Owner
Joined: 22 May 2004 Posts: 1576 Location: CheapestAdultScripts.com
|
|
|
|
|
|
|
Posted: Wed Nov 08, 2006 5:39 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
make the right code to:
<body><table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="30%" align="left" valign="top">
<?php include("menu.php"); ?>
</td>
<td width="80%" align="left" valign="top">
<?php if(isset($niche1)) include "so/sohtml/amtmbs.php"; elseif(isset($niche2) include "niche2.php"; ?>
</td>
</tr>
</table>
</body>
keep the include function syntax proper, don't forget the ending ; symbols, and make sure you type the correct path to the templates.
Let me know.. _________________
|
|
|
|
|
|
|
|
juggernaut
Joined: 30 Aug 2005 Posts: 7
|
|
|
|
|
|
|
Posted: Wed Nov 08, 2006 6:04 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
Well I found one of the problems. It's my host. For some reason the page is not updating correctly. Not sure what is wrong as I never had this issue with them. Dreamweaver was saving the files locally, even when I pushed them to the server via DW they would not take. I cleared out my browser settings and refreshed with f-5 and still no good. I then named the page title to test and it never shows in the browser. So then I figure ok back to the old way. I open the index in notepad, make sure the changes are there and upload via ftp. Still nothing took, so there is surly something up with the host. I have a server in my house and decided to push the local site to it and run the test, and low and behold everything works. So now it's on the phone with the hosting company. Hey thanks man.. You rock.... |
|
|
|
|
|
|
|
kaktus Owner
Joined: 22 May 2004 Posts: 1576 Location: CheapestAdultScripts.com
|
|
|
|
|
|
|
Posted: Wed Nov 08, 2006 6:10 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
no problems man, best wishes _________________
|
|
|
|
|
|
|
|
juggernaut
Joined: 30 Aug 2005 Posts: 7
|
|
|
|
|
|
|
Posted: Mon Nov 13, 2006 4:46 am Post subject: |
|
|
|
|
|
|
|
|
|
|
Finnaly got the issue resolved with the host. Still could not get it to work. After a little reading got it going with this.
---------
<td align="center" valign="top" scope="col"><?php if(isset($_GET['niche1'])) include "so/sohtml/amtmbs.php"; elseif(isset($_GET['niche2']))
-------------
Kat had to send you a PM. Having that old password issue again. |
|
|
|
|
|
|
|
kaktus Owner
Joined: 22 May 2004 Posts: 1576 Location: CheapestAdultScripts.com
|
|
|
|
|
|
|
Posted: Mon Nov 13, 2006 12:02 pm Post subject: |
|
|
|
|
|
|
|
|
|
|
oh, yes.. your server has register_globals disabled... glad you make it working.. _________________
|
|
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2002 phpBB Group
|
|
phpBB Template designed by SkaidonDesigns |
|
| |