76

(6 replies, posted in PunBB 1.2 discussion)

im using Ad on my website also (because my site is about advertising); i try just to put 2 banners at the bottom and at the header. My ads will rotate every time load pages so dont worry about if u have many ads to show. furthermore, it wont make visitors annoy when have ads after every posts or pop-up etc...

great man wink good luck with that; still waiting tongue

elbekko wrote:

I'll post the join query later on, but now I have something else to do smile

im waitting for you smile thanks

cool thank you very much

hi guys;

im changing the domain name ;eventhough still using the same hosting / database. I wonder do i need to reinstall the whole punbb and will i lost all the MOD/ posts inside? or i can just simple by changing the URL ,sopy and paste it?

Thanks

Regards

Tubby wrote:

then you would have to merge it with a table that does have subject. smile hope i cleared things up for you lol

i know what u mean and i tried it already; but it just shows random subject instead...

$resultb = $db->query('SELECT *  FROM '.$db->prefix.'Ratings AND '.$db->prefix.'topics ORDER BY rate DESC LIMIT 5 ') or error('Unable to fetch user data', __FILE__, __LINE__, $db->error());
while ($datab = $db->fetch_assoc($resultb))
{
echo "".'<li><a href="http://xxxx/Forum/viewtopic.php?id='.$datab['topic_id'].'">'.pun_htmlspecialchars($datab['subject']).'</a></li> '.""; 
}

thanks for your reply

following your code; in the Ratings table doesnt have subject though sad thanks for your reply btw

<?php

$resulta = $db->query('SELECT subject FROM '.$db->prefix.'topics  ORDER BY `id`  ') or error('Unable to fetch user data', __FILE__, __LINE__, $db->error());
$dataa = $db->fetch_assoc($resulta);

$resultb = $db->query('SELECT rate, topic_id  FROM '.$db->prefix.'Ratings ORDER BY rate DESC LIMIT 5 ') or error('Unable to fetch user data', __FILE__, __LINE__, $db->error());
while ($datab = $db->fetch_assoc($resultb))
{
echo "".'<li><a href="http://xxxx/Forum/viewtopic.php?id='.$datab['topic_id'].'">'.pun_htmlspecialchars($dataa['subject']).'</a></li> '.""; 
}

?>

i just try to use this one so it can show the highest rate topic, however it always just appear all the same subject though.. eventhough it sort the topics with the rate right...can anyone know how to fix it please?

hi;

is it possible to show the post with the most rating ?

thanks

still cannot; i did exactly everything which showed in the readme file though ....

ok thanks im trying now

hi;

i just insstalled this and got this error when access to profile

Parse error: parse error, unexpected T_IF in /xxx/httpdocs/Forum/profile.php on line 959

whats wrong with it?

88

(3 replies, posted in PunBB 1.2 troubleshooting)

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

thanks

89

(3 replies, posted in PunBB 1.2 troubleshooting)

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

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