1 (edited by mystic 2006-10-20 19:28)

Topic: problem with the links

hi guys;
im using punbb atm and i integrated it to my main page. i got the login box form outside now im trying to show the header navigation of the forum at the front page also . but i always got this problem.

i made 1 function with a file like this

<?php
function login_nav() {
global $lang_common, $pun_user;


if ($pun_user['is_guest'])
    {
        ?>
        <? echo "<a href=\"xxxx/index.php\">ome Page</a>";?> | 
        <? echo "<a href=\"xxxx/Forum/index.php\">Forum</a>";?> | 
    <? echo "<a href=\"xxxx/Forum/userlist.php\">".$lang_common['User list']."</a>";    ?> | 
     <? echo "<a href=\"xxxx/Forum/misc.php?action=rules\">".$lang_common['Rules']."</a>";?> | 
        <? echo "<a href=\"xxxx/Forum/search.php\">".$lang_common['Search']."</a>"; ?> |
        <? echo "<a href=\"xxxx/Forum/register.php\">".$lang_common['Register']."</a>";?> | 
        <? echo "<a href=\"xxxx/index.php#login\">".$lang_common['Login']."</a>"; 
         ?> | 
        
<? 
    }
    else
    {
        ?>
        <? echo "<a href=\"xxxx/index.php\">Home Page</a>";?> | 
        <? echo "<a href=\"xxxx/Forum/index.php\">Forum</a>";?> |
        <? echo "<a href=\"xxxxForum/userlist.php\">".$lang_common['User list']."</a>";    ?> | 
     <? echo "<a href=\"http://xxxxt/Forum/misc.php?action=rules\">".$lang_common['Rules']."</a>";?> | 
        <? echo "<a href=\"xxxx/Forum/search.php\">".$lang_common['Search']."</a>"; ?> |
<? echo        "<a href=\"http://xxxx/Forum/profile.php?id=".$pun_user['id']."\">".$lang_common['Profile']."</a>"; ?> | 
<? echo        "<a href=\"http://xxxx/Forum/login.php?action=out&id=".$pun_user['id']."\">".$lang_common['Logout']."</a>"; ?>
<?
        
    }
        
    
    }
?>

then i use it at my main page

define('PUN_ROOT', 'xxxx/Forum/'); 
require 'xxx/Forum/include/common.php';
include 'xxx/Forum/login_navephp';
login_menu();

when i use this funtion and the login funtion, they always made my website not appear right; i mean all my existing navigationn cant use anymore or i cant jump to any other pages on my website. If i use only the login funtion then everything is fine.

Furthermore, when i tried to put 

require 'xxxx/Forum/include/common.php';

to the head or anywhere else on my website ; it does have the same problem ( because i want to use other functions also...) . So now i can only use the login function. I only can use this code exactly right above the code to call login funtionc. I dont know why... I though there were some problems with the code, but so far i cant fine any error in it...

Please teach me how.

Thanks

I love sky - i love flowers - and i love myself :D

Re: problem with the links

oh i just tried to put the login_nav(); just under the login funtionc it works great; but the problem is i dont want to put the navigation link at the bottom sad please help guys

I love sky - i love flowers - and i love myself :D

Re: problem with the links

Could we get a link (and possibly a link to a page experiencing the problem)?

Re: problem with the links

ive sent u an email to explain why i dont show the error web page , please check your mail.

thanks

I love sky - i love flowers - and i love myself :D