1 (edited by lie2815 2007-05-23 01:28)

Topic: puntoolbar

I just installed the puntoolbar and in viewtopic.php I get the following error:

Parse error: parse error, unexpected T_STRING in <mysite>/forum/include/parser.php on line 162

Any help? Here is the code, starting with line 147:

// Deal with strpos() returning false when the string is not found
        // (65536 is one byte longer than the maximum post length)
        if ($c_start === false) $c_start = 65536;
        if ($c_end === false) $c_end = 65536;
        if ($q_start === false) $q_start = 65536;
        if ($q_end === false) $q_end = 65536;

        // If none of the strings were found
        if (min($c_start, $c_end, $q_start, $q_end, $q2_start) == 65536)
            break;

        // We are interested in the first quote (regardless of the type of quote)
        $q3_start = ($q_start < $q2_start) ? $q_start : $q2_start;

        // We found a [quote]or a [quote=username]if ($q3_start  min($q_end, $c_start, $c_end))
        {
            $step = ($q_start  $q2_start) ? 7 : strlen($matches[0]);

            $cur_index += $q3_start + $step;

            // Did we reach $max_depth?
            if ($q_depth == $max_depth)
                $overflow_begin = $cur_index - $step;

            ++$q_depth;
            $text = substr($text, $q3_start + $step);
        }
FluxBB - v1.4.8

Re: puntoolbar

While we're at it... another problem:
the plugin needs a file include/cache_puntoolbar.php and in viewtopic.php there is a file needed called include/puntoolbar.php
Only cache_puntoolbar.php is provided in the mod zip package.

FluxBB - v1.4.8

3 (edited by soonotes 2007-04-25 04:52)

Re: puntoolbar

       // We found a [quote]or a [quote=username]if ($q3_start  min($q_end, $c_start, $c_end))

should be

        // We found a [quote]or a [quote=username]if ($q3_start < min($q_end, $c_start, $c_end))

edit, for some reason the site wants to put the if ($q3_start... on the same line as the commented part. I'm guessing it's not on the same line in your code.

As for the missing file not sure since I cannot find this mod anywhere.

4 (edited by lie2815 2007-04-25 04:51)

Re: puntoolbar

it's on punbb.fr

EDIT: Wait a sec... did you actually change anything after that "should be"?

FluxBB - v1.4.8

Re: puntoolbar

I changed something but it didn't show up. Like I said in my edit the if statement should be on a different line, don't know why the forum won't put it there. Is it on a different line in your parser.php

Re: puntoolbar

Yeah it is, so that should not be the problem. And also, this thing doesn't even come from the mod, so...

FluxBB - v1.4.8

Re: puntoolbar

The part of parser.php you posted looks exactly like it should then. Double check the parts of it that were modified.

As for the file cache_puntoolbar.php it looks like it was named incorrectly and should be puntoolbar.php

Re: puntoolbar

No, the plugin needs a file called cache_puntoolbar.php
I just took puntoolbar.php from an older version (1.3)

FluxBB - v1.4.8

Re: puntoolbar

Yeah, but it generates the cache file.

Re: puntoolbar

Not really. If the cache file isn't there, it has problems...

FluxBB - v1.4.8

11

Re: puntoolbar

yes, /include/cache_puntoolbar.php is necessary for the mod to work

Re: puntoolbar

Ok, and now?
Who wrote that mod?

FluxBB - v1.4.8

13

Re: puntoolbar

vin100

14

Re: puntoolbar

http://punbb.org/forums/viewtopic.php?pid=92795#p92795