Problem with Links.. PHP

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
ronairis
Forum Newbie
Posts: 2
Joined: Tue Oct 25, 2005 6:03 am

Problem with Links.. PHP

Post by ronairis »

feyd | Please use

Code: Select all

and

Code: Select all

tags where appropriate when posting code. Read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color]


we're having a problem with our php site.. regarding the links.
it works well with our local server (localhost server:apache) but when we uploaded to our server.. the links wont work properly.

we are using these codes:
for our home.php

Code: Select all

<?php $imagedir = 'images/';?>
<?php include('includes/config.php')?>
<?php include('admin/function.php')?>
<?php include('vda/vdaemon.php')?>
<?php 
if($sesscheck > 0 && isset($_SESSION['atpm_level']) && $_SESSION['atpm_level'] <= 7){
	if(!isset($HTTP_GET_VARS['page'])){
		$page = 'inc_home.php';
		$pageb = 'inc_home_proc.php';
		}
	if(isset($HTTP_GET_VARS['page'])){
	$link = $_SERVER['PHP_SELF'].'?page='.$_GET['page'];
	if(isset($HTTP_GET_VARS['page'])){
		$page = 'inc_'.$_GET['page'].'.php';
		$pageb = 'inc_'.$_GET['page'].'_proc.php';
	}
}
$_SESSION['atpm_redirect']= html_entity_decode(geturl());
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title><?php echo $sitetitle?></title>
<link href="scripts/csses.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="scripts/jsses.js"></script>
</head>
<body>
<table width="100%"  border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td align="center" valign="top"><table width="80%"  border="0" cellspacing="0" cellpadding="10">
      <tr align="left" valign="top">
        <td width="200"><?php include('menu.php')?></td>
        <td><?php 
		if(file_exists($pageb) && file_exists($page)){
			include($pageb);
			include($page);
		}else {
			include('inc_home.php');
			}?></td>
      </tr>
    </table></td>
  </tr>
</table>
</body>
</html>
<?php VDEnd();
}//if logged in
else {
	$goto = 'index.php';
	gotoa(1, $goto, 0);
}?>
and for the links..

Code: Select all

<table width="100%" cellpadding="0"  cellspacing="0" class="forumline">
  <tr>
    <td align="left" valign="top"><table width="100%"  cellspacing="1" cellpadding="8">
      <tr>
        <th height="28" align="left" valign="middle" class="thHead" height->Welcome!</th>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><span class="gen"><?php echo data(1, $_SESSION['atpm_userid'], 'user','user_fname','user_id','Query user first name').'  '.data(1, $_SESSION['atpm_userid'], 'user','user_lname','user_id','Query user last name')?></span></td>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><a href="home.php" class="genmed"><img src ="images/home.jpg" border = "0"></a></td>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><a href="home.php?page=schedule&sked=4" class="genmed"><img src ="images/sched.jpg" border = "0"></a></td>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><a href="home.php?page=dtr" class="genmed"><img src ="images/dtr.jpg" border = "0"></a></td>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><a href="home.php?page=account" class="genmed"><img src ="images/account.jpg" border = "0"></a><a href="admin.php?page=user&do=add" class="genmed"></a></td>
      </tr>
      <tr>
        <td align="left" valign="middle" class="row1"><a href="process.php?page=logout" class="genmed"><img src ="images/out.jpg" border = "0"></a></td>
      </tr>
    </table></td>
  </tr>
</table>
help! what could possibly be wrong? tnx in advance.


feyd | Please use

Code: Select all

and

Code: Select all

tags where appropriate when posting code. Read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color]
ronairis
Forum Newbie
Posts: 2
Joined: Tue Oct 25, 2005 6:03 am

Post by ronairis »

help
Last edited by ronairis on Thu Oct 27, 2005 2:32 am, edited 1 time in total.
User avatar
Jenk
DevNet Master
Posts: 3587
Joined: Mon Sep 19, 2005 6:24 am
Location: London

Post by Jenk »

That error message is telling you exactly what is wrong..
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

Where is the function gotoa?
PS. Learn to indent. Very dificult to read your code.
Post Reply