1

(8 replies, posted in PunBB 1.3 troubleshooting)

I semi-fixed my problem with the Admin panel after jumping through some unnecessary hoops.

I installed a new version of 1.3 and 1.3.2 each with their own databases and pretended to have separate forums. Looking in my Config file for one of them I noticed a line that was for some weird reason missing from my config.php file for my forum to begin with.

$base_url = 'http://www.jasoco.net/xxxxxx';

The Base URL variable wasn't defined for some reason causing all the links in the Admin folder to point to the admin folder instead of where they should go. (i.e. adding /admin to every link including ones that already pointed to /admin making it /admin/admin.)

Why the line was missing? I don't know. And why it never caused a problem before? I have no idea.

This doesn't solve your problem, which is the problem I started with too, but it at least fixes mine back to what it was before I screwed it all up. The DB is set to 1.3 instead of 1.3.2 and the software is 1.3 as well. I'll try to upgrade some other day. For now I'm just exhausted from trying to fix things. Also, I learned my lesson again. DON'T FORGET TO DOWNLOAD THE DATABASE BACKUP AS WELL AS THE ORIGINAL FILES! How many times must I learn that? Wait... no... this was the first time I forgot. Nevermind. It was a brain fart. I was watching Tropic Thunder at the time. I guess the fart jokes got to me.

UNFORTUNATELY, the error still stands if I uncomment the two lines I had to comment to bypass. Safeties in place to prevent problems that are just causing problems themselves.

// Verify that we are running the proper database schema revision
if (defined('PUN') || !isset($forum_config['o_database_revision']) || $forum_config['o_database_revision'] < FORUM_DB_REVISION || version_compare($forum_config['o_cur_version'], FORUM_VERSION, '<'))
    error('Your PunBB database is out-of-date and must be upgraded in order to continue. Please run <a href="'.FORUM_ROOT.'admin/db_update.php">db_update.php</a> in order to complete the upgrade process.');

I commented this part out because if I don't, the forum thinks it is a different version. But upgrading gives me that error that it's already up to date. So it's an infinite confusion loop. THIS is the problem I must fix. And you yourself.

Durkin, if you have a second and access to the files, open ESSENTIALS.PHP and comment those lines too. If only for a minute. And tell me if it "fixes" your problem for now. In that you can load the forum fine afterwards. If it works, then we have the same problem. With the same "fix". And should wait for an official punBB person to reply.

"Comment" means to put two /'s in front of the two lines that don't have it. In my file it's lines 108 and 109. Place // before the lines that say if (defined and the one with error( at the beginning.

2

(8 replies, posted in PunBB 1.3 troubleshooting)

I've reverted to my old forum files (1.3.0) but I made a mistake of not backing up my database (Totally forgot about it), so I manually changed the config table cell "1.3.2" back to "1.3", but still got the "must be upgraded" error. So I commented out that error checking line in the essentials.php file as a temporary measure since I really screwed things up with my database.

When I originally started the upgrade, I got errors on the install page which pretty much should have told me to stop right there, but I clicked Upgrade anyway and got errors at the tops of all the pages, but it still continued its duty of "converting SQL tables".

Now that I'm back to 1.3.0 my Admin panel is screwed up. All links inside the panels under the /admin/ directory point to /admin/whatever. For instance, the links that should point back to the index points to /admin/index.php. And any links that point to pages under /admin/ point to /admin/admin/.

What the heck?

What changed and why is it all screwed up?

Now I have to figure out what was changed in the database between 1.3 and 1.3.2 so I can manually set it all back because the forum still thinks the database is out of date.

*sigh*

I never should have woken up today.

Edit: Well, my forum is totally screwed up now. Extensions I don't even have turned on are giving errors. The Admin pages are borked. This is a disaster! I need some serious help fixing this. sad

3

(8 replies, posted in PunBB 1.3 troubleshooting)

I don't get what the heck happened? The forum thinks the database is a different version, but at the same time knows it's the right one? What? What is triggering this error?

4

(8 replies, posted in PunBB 1.3 troubleshooting)

I too am having the same problem. It's a disaster! What am I supposed to do?

An error was encountered

Your PunBB database is out-of-date and must be upgraded in order to continue. Please run db_update.php in order to complete the upgrade process.

Click the link and it gives me this:

An error was encountered

Your database is already as up-to-date as this script can make it.

Help! ASAP!

5

(13 replies, posted in PunBB 1.3 additions)

If it helps any, here is a truncated version of the old Active Topics Mod file I used...

<?php
    $active_topic_limit = 20; // change this to the number of active topics you want to display.
    $result = $db->query('SELECT t.*, f.forum_name FROM '.$db->prefix.'topics AS t INNER JOIN '.$db->prefix.'forums AS f ON f.id=t.forum_id LEFT JOIN '.$db->prefix.'forum_perms AS fp ON (fp.forum_id=f.id AND fp.group_id='.$pun_user['g_id'].') WHERE (fp.read_forum IS NULL OR fp.read_forum=1) AND t.moved_to IS NULL ORDER BY t.last_post DESC  LIMIT '.$active_topic_limit) or error('Unable to fetch topic list', __FILE__, __LINE__, $db->error());
?>
<table cellspacing="0" cellpadding="0" border="0">
<?php
// If there are topics in this forum.
if ($db->num_rows($result))
{
  $new_border = '';
  while ($cur_topic_act = $db->fetch_assoc($result))
  {
    $oldtopicisnew = $topicisnew;
    $item_status = '';

    if ($pun_config['o_censoring'] == '1')
      $cur_topic_act['subject'] = censor_words($cur_topic_act['subject']);

    //$last_post = ''.pun_htmlspecialchars($cur_topic_act['subject']).'</a>';
    $last_post = '<a href="viewtopic.php?id='.$cur_topic_act['id'].'&amp;action=new" class="atthreadname">'.pun_htmlspecialchars($cur_topic_act['subject']).'</a>';

    if (!$pun_user['is_guest'] && $cur_topic_act['last_post'] > $pun_user['last_visit'])
    {
      $show_icon = '<div class="icon inew"><div class="nosize"><!-- --> There are new posts</div></div>';
    } else {
      $show_icon = '<div class="icon"><div class="nosize"><!-- --> There are new posts</div></div>';
    }
?>
     <tr<?php if ($item_status != '') echo ' class="'.$item_status.'"'; ?>>
        <td class="tcl<?php echo $div_status; ?>"<?php echo $new_border; ?>>
            <div class="intd">
                <?php echo $show_icon; ?>
                <div class="tclcon">
                    <?php echo $last_post; ?> by <?php echo $posterwho; ?>
                </div>
            </div>
        </td>
        <td class="tc2"<?php echo $new_border; ?>><?php echo $cur_topic_act['num_replies']; ?></td>
        <td class="tc3"<?php echo $new_border; ?>><?php echo $cur_topic_act['num_views']; ?></td>
        <td class="tcr"<?php echo $new_border; ?>><?php echo '<a href="viewtopic.php?pid='.$cur_topic_act['last_post_id'].'#p'.$cur_topic_act['last_post_id'].'">'.format_time($cur_topic_act['last_post'],true).'</a>'; ?> by <?php echo $lastposterwho; ?></td>
    </tr>
<?php
  }
}
?>
</table>

As you see, 1.3 has changed everything drastically I can't even begin to figure out how to grab stuff from the SQL result query.

6

(13 replies, posted in PunBB 1.3 additions)

Thanks. But can you help me figure out how to get that into the correct arrays?

Basically so I can go through with the For...Next loop and put the values into the right rows.

($hook = get_hook('vf_qr_get_topics')) ? eval($hook) : null;
$result = $forum_db->query_build($query) or error(__FILE__, __LINE__);

I have this so far, but how do I rip the stuff out of the Result array and place it into all the appropriate arrays like the Topic title, number of replies and views, time posted and user and etc.?

Thanks

7

(13 replies, posted in PunBB 1.3 additions)

Nobody? I can't get the hang of the new structure.

8

(154 replies, posted in Supported extensions)

The links have stopped working. sad

9

(13 replies, posted in PunBB 1.3 additions)

I just upgraded from 1.2 but am missing some stuff that my users really really miss so I am trying to recreate them piece by piece. But everything's changed so much none of my old hacks work.

1.2 had a Mod called "Active Topics Mod" where I could drop in an Include call into say the Index.php page and the ViewTopic.php pages and display a list of say the last 20 replied to topics. My users used this more than the actual forum lists themselves. (Yeah I know about the links at the top, they're not the same) So I have been trying to recreate it. Thinking it should be easy. Just call the database and ask for 20 items sorted by last update time and viola...

But I just can't get the syntax right.

Can someone help with some starter code? Remember that it needs to be able to be placed in pages that are already established. Namely the Index and Topic pages.

I already have the "table" set up, I just need to drop the data into it.

10

(1 replies, posted in PunBB 1.2 show off)

GeekPub is a forum that was founded by my friend in 2002 or so when FunXbox.com (FXB was an Xbox fan and news site he owned for a while.) went under. (It was sold to XboxAdvanced and disassembled.) He started it on phpBB and hired me to be the webmaster. Well, phpBB was pretty messy. But I didn't know about any viable replacement that was free until another forum I frequent switched from phpBB to punBB. Eventually I took over the forum completely and now it belongs to me.

So when my host decided to destroy my MySQL database leaving me with only half of it and the backup I so smartly made a few days before, I realized that now was my chance. So I switched to punBB and haven't been happier. I haven't had this much fun coding a forum ever. phpBB was never this fun. wink

No longer an Xbox discussion forum, you can talk about anything you want. We currently have a nice selection of loyal members but welcome more.

http://www.jasoco.net/geekpub/


My version is highly modified. I just go crazy. If there's something I want to do, and a MOD doesn't already exist, I do it myself. Damn the consequences. I know, most people wouldn't suggest it, but I know what I'm doing so it's all good. Currently my version is 1.2.11+. I added the plus to signify the modifications. I know, I'm a few versions behind, I've just been really busy. Eventually I'll update it to the current version when I have time.

Let me list some of the mods I've put in...

First off is the default Style. Looks awesome in Safari with shadowed text.

Randomly changing taglines at the top of the page.

Active Topic List at the bottom of the Index and ViewTopic pages shows the 20 most recently updated topics.

Various custom UBB tags, among them my very own Table tags, a Spoiler tag with hover effect, Foreground coloring, Background coloring, Text Size, Text face, the Flash Embedding tag, a special Elite tag* and an Explanation tag which allows you to add a "Tooltip" to text which can be used to provide an explanation for a selection of words so you don't have to use parinthesized text. It's hard to explain without an explanation tag. You can see it in action in many threads there.

A lot of cool smileys including video game characters, TV and movie personalities as well as the standard ones and some rating smileys.

On the ViewTopic page, a bottom mounted list of links appears allowing you to Jump to the Top or the page, to the newest post, back to the index or even sort the topic in Descending order.

A mod I call the "Double-post eliminator" that removes the avatar and extra code from posts by the same author when they post right after their other posts (Two or more in a row by the same person.) makes it look less cluttered and allows you to make out strings of peoples talking easier.

Each member can choose their own styling for their custom title.

Each members "User Options" are now in a pull-down menu that appears when you click their name. (Like vBulliten does.)

Each members browser and OS string is saved with each post. This info is then used later in the topic to tell me what browser and OS they were on when they posted. It was originally added in to take a survey of what each person uses.

*Elite Tag: On my forum is a hidden forum called "The Boom-Boom Bar". It is only accessible to certain members (Anyone who registers, promises to post a lot and asks nicely can become one.) and was created to serve one purpose. Hide stuff from the internet. I created it as a way to talk about my love life without the one I am interested in somehow stumbling onto our conversation. It is now used to hide other talk as well. The purpose of the Elite Tag is so when you are in a non Elite forum and you need to reference something exclusive to the BBBar, you can hide it from non Elite members. Pretty clever if I do say so myself.

11

(45 replies, posted in News)

Doesn't work. If I put it in, the Admin Options page gives an error until I remove it. Same thing happened when I tried to upgrade from 11 to 12. Errors in most files.

So I just gave up.

I have a weird highly modified version of 1.2.11 on my forum. So I have to manually update via the Difference logs each time.
http://www.jasoco.net/geekpub/index.php

elbekko wrote:

Yes, well, the reason I didn't make it a link because if your style is set to underline links, you'd have small lines under your smilies wink
Naturally, this works too, and I could eliminate the underlining with CSS, but if you have a bunch of smilies that would really increase page size =/

Not if you do this...

http://www.jasoco.net/data/files/images/Smiley%20Example.jpg

No, it's not an IFrame or a Frame of any sort.

It's all CSS, baby.

<fieldset style="margin-left:4px; line-height:1.5em; width:22%; float:right; margin-top:16px; text-align:left; text-decoration:none;BORDER-STYLE: solid;BORDER-WIDTH: 1px;padding: 0 0 0 10px;">
<legend>Smilies</legend><div style="overflow:auto; height:300px; padding: 2px;">

...

</div></fieldset>

An extra DIV can do wonders. And Overflow is just awesome.

Also, no pilfering my custom "character" smileys, please. Make your own.

That might work. I'll take a look see.

I need to know when certain members are coming and going. Call it a Big Brother modification if you want.

I don't need a new login page as everyone is auto-logged-in. So what I need to do is find the file that is called when that login is registered. Then add the user logging in, the current time and their IP into a new table.

Don't ask why. Doesn't matter. I know it's possible, I just want to do it right.

Basically what I'm looking to do is add code to whatever controls user logging in and adds their name and time of login to a new table.

Then create a page (That only certain people would have access to.) that displays all this info.

I guess the real part I need help with is where the code should go for adding a row to the table I'll be using.

I'll have to create a new table in PHPMyAdmin. I guess I'd call it "loginlog" or something. It would have three columns. Username, IP and Time. Pretty obvious.

The whole reason I am doing this is because I need to know when and if certain users are visiting. You may say it would get too big too fast wouldn't it? Not really. My forum is really really small. If we have to, we can modify it to delete older entries after a week or month or whatever.

So I guess the first question is, what file should the Table modification code go in? And what code should be used? (I'm new to MySQL and the controlling of it with PHP. I'm able to easily read tables. But I've never made code that adds to tables and I don't want to screw anything up.) What file is used when a user first accesses a punBB forum and is registered to the database as "Logged in and online"?

I dunno. My modification is working 100% perfectly. Click the image, the code shows up.

I'll check out your new code just to see if that works too.

Nope. That doesn't work either. sad

I can't see what could be wrong. And I've been trying everything.

I even rechecked the code I inserted.

Wait! I think I got it. I replaced that whole If section with this instead:

if(substr_count($smilies,$smiley_img[$key]) > 0)
    {
    continue;
    }

I don't know if removing the parse_message part is going to screw it up though. But for some reason, if I put the parse_message back, it doesn't work. Only removing parse_message part and changing the smiley_text to smiley_img it works. I noticed that using smiley_text is only going to check an array that will never have duplicate entries. It's smiley_img that has all the duplicate entries in it. I thought this was weird so I tried it out. And now it works.

Yep. It's there.

Works almost perfect. Except that it's still showing duplicate smileys on my forum.

http://www.jasoco.net/geekpub/index.php

It's a real bugger. Yes, I installed the .4 version.

Hello. I just had this same problem a few minutes ago and that solution also worked for me. But I am wondering, is this a server problem? Or a punBB problem? And would there be a way to hack punBB to know when this is happening? I had a user email me a few weeks ago with this same problem but it was during work so I didn't get the email until I got home at which point it had fixed itself and the user was back to posting again. But this time I was home when it happened. So it's even more annoying that it was a real problem and not a fluke.

BTW, the error started coming up after my host or server (Where the site is hosted) went down for a few minutes. Could that be related?

I just want to fix this as soon as possible. Because I can't tell how often this is gonna be happening.

Edit: By the way again, my server is off by 10 hours (Behind. It says 1:56PM now when it's really 11:56PM.) I'm Eastern. The server is Eastern and my timezone is set to -5 Hours (EST).

21

(7 replies, posted in PunBB 1.2 troubleshooting)

Okay. I think I have fixed it. Seems both the Footer.php file and the Active Topics MOD I used both had the same "cur_topic" variable. I just changed the "cur_topic" in the Active MOD to "cur_topic_act" and all is well.

Problem solved!

22

(7 replies, posted in PunBB 1.2 troubleshooting)

Well, actually the only thing I can think of is the "Active Topics" mod I installed in the ViewTopic page. It comes after the Quick Reply and before the footer. I bet that's the problem. I'll have to figure out how to pass the state around the ViewTopics file.

Edit: Yep. That's it. Okay.. so what variable needs to be passed to the footer to make it work again?

I'm assuming the Active Topics file I used has a conflicting "Locked/Open" variable with the same name. So when it loads a list of active topics it's using the "Locked/Open" state of the last topic in the list. So my question is what variable does the footer use to display whether it's opened or closed? Guess I'll go look.

23

(7 replies, posted in PunBB 1.2 troubleshooting)

I have. But not that I can think would change that. Isn't that part in the footer anyway?

24

(7 replies, posted in PunBB 1.2 troubleshooting)

It doesn't show like that for me. It stays as "Close". That's the first place I checked.

I'm surprised I don't see a way to unlock a topic I locked. (On my forum)

Is there a way to add this in or a way to unlock the topic that I am missing somewhere?

Edit: I found a way to unlock it by Moderating a forum. But I assume there's no way to simply unlock the topic from within the topic itself?