Problem mit Advanced BBCode Box 3 Einstellungen

Du hast Probleme beim Einbau oder bei der Benutzung eines Mods? In diesem Forum bist du richtig.
Forumsregeln
phpBB 3.0 hat das Ende seiner Lebenszeit überschritten
phpBB 3.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 3.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf die neuste phpBB-Version, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
Benutzeravatar
bullydogge88
Mitglied
Beiträge: 81
Registriert: 12.11.2012 08:46
Wohnort: Nrw
Kontaktdaten:

Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von bullydogge88 »

Hallöchen,
ich hab heute fest gestellt das ich nicht mehr im ACP--->Beiträge--->Advanced BBCode Box 3 die Einstellungen ändern kann bzw. ich komm da nicht mehr hin.
Beim Klick auf ABBC3 Einstellungen bekomm ich diese Fehlermeldung: Fatal error: Cannot redeclare url_to_bbvideo() (previously declared in /users/hundeforum/www/phpBB3/includes/abbcode.php:2277) in /users/hundeforum/www/phpBB3/includes/abbcode.php on line 2308
Das gleiche bei ABBC3 BBCodes.
Das ist die Stelle 2277-2308 in der /includes/abbcode.php:

Code: Alles auswählen

function url_to_bbvideo($text)
{
    global $bbcode, $user;

    // if no BBCodes are on page, load them up
    if (empty($bbcode))
    {
        $bbcode = new bbcode();
        $bbcode->bbcode_cache_init();
    }

    // get array of all BBvideos
    static $abbcode_video_ary = array();
    if (empty($abbcode_video_ary))
    {
        $abbcode_video_ary = abbcode::video_init();
    }

    // check to see if any URLs can be converted into BBvideos
    foreach ($abbcode_video_ary as $video_name => $video_data)
    {
        // For now we only will apply this to video sites...BBvideos with ID's less than 200
        if ( (strpos($text, $video_name) !== false) && isset($video_data['id']) && ($video_data['id'] <= 200) )
        {
            // Run URL matches through the BBvideo_pass function to turn them into embedded BBvideos
            $text = preg_replace_callback('#<!-- [lmw] --><a class="[^"]*" href="(.*?)">.*?<\/a><!-- [lmw] -->#i', create_function('$matches', 'global $bbcode; return $bbcode->BBvideo_pass($matches[1], null, null);'), $text);
            break;
        }
    }

    return $text;
}
Kann/mag mir vielleicht jemand helfen?
Link zur Mod: https://www.phpbb.com/customise/db/mod/ ... ode_box_3/
http://hundeforum.bplaced.net/phpBB3
Heilir Æsir, heilar Ásynjur
og öll ginnheilög go
Benutzeravatar
Miriam
Mitglied
Beiträge: 12310
Registriert: 13.10.2004 07:18
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von Miriam »

Also an diesem Code liegt's nicht. Hast Du mal den Cache geleert?

Wenn das nicht hillft: Zeig mal die /includes/abbcode.php her (mittels PasteBin)
Gruss, Miriam.
Ich schmeiß' alles hin und...
... lasse es liegen
Benutzeravatar
bullydogge88
Mitglied
Beiträge: 81
Registriert: 12.11.2012 08:46
Wohnort: Nrw
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von bullydogge88 »

Japp sämtliche Caches geleert gehabt.

Hier die Datei: https://www.phpbb.de/support/pastebin.p ... iew&s=1189
http://hundeforum.bplaced.net/phpBB3
Heilir Æsir, heilar Ásynjur
og öll ginnheilög go
Benutzeravatar
Miriam
Mitglied
Beiträge: 12310
Registriert: 13.10.2004 07:18
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von Miriam »

Also irgendwie hört der Code auf in dem Moment, in dem es spannend wird.
Gruss, Miriam.
Ich schmeiß' alles hin und...
... lasse es liegen
Benutzeravatar
BNa
Valued Contributor
Beiträge: 3169
Registriert: 12.04.2010 23:51
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von BNa »

Ersetze mal das

Code: Alles auswählen

    function url_to_bbvideo($text)
    {
        global $bbcode, $user;

        // if no BBCodes are on page, load them up
        if (empty($bbcode))
        {
            $bbcode = new bbcode();
            $bbcode->bbcode_cache_init();
        }

        // get array of all BBvideos
        static $abbcode_video_ary = array();
        if (empty($abbcode_video_ary))
        {
            $abbcode_video_ary = abbcode::video_init();
        }

        // check to see if any URLs can be converted into BBvideos
        foreach ($abbcode_video_ary as $video_name => $video_data)
        {
            // For now we only will apply this to video sites...BBvideos with ID's less than 200
            if ( (strpos($text, $video_name) !== false) && isset($video_data['id']) && ($video_data['id'] <= 200) )
            {
                // Run URL matches through the BBvideo_pass function to turn them into embedded BBvideos
                $text = preg_replace_callback('#<!-- [lmw] --><a class="[^"]*" href="(.*?)">.*?<\/a><!-- [lmw] -->#i', create_function('$matches', 'global $bbcode; return $bbcode->BBvideo_pass($matches[1], null, null);'), $text);
                break;
            }
        }

        return $text;
    } 
mit dem

Code: Alles auswählen

    if (!function_exists('url_to_bbvideo'))
    {
    function url_to_bbvideo($text)
    {
        global $bbcode, $user;

        // if no BBCodes are on page, load them up
        if (empty($bbcode))
        {
            $bbcode = new bbcode();
            $bbcode->bbcode_cache_init();
        }

        // get array of all BBvideos
        static $abbcode_video_ary = array();
        if (empty($abbcode_video_ary))
        {
            $abbcode_video_ary = abbcode::video_init();
        }

        // check to see if any URLs can be converted into BBvideos
        foreach ($abbcode_video_ary as $video_name => $video_data)
        {
            // For now we only will apply this to video sites...BBvideos with ID's less than 200
            if ( (strpos($text, $video_name) !== false) && isset($video_data['id']) && ($video_data['id'] <= 200) )
            {
                // Run URL matches through the BBvideo_pass function to turn them into embedded BBvideos
                $text = preg_replace_callback('#<!-- [lmw] --><a class="[^"]*" href="(.*?)">.*?<\/a><!-- [lmw] -->#i', create_function('$matches', 'global $bbcode; return $bbcode->BBvideo_pass($matches[1], null, null);'), $text);
                break;
            }
        }

        return $text;
    }
    } 
Die ABBCB3 ist mE. eh zu komplex gestaltet und 'überfunktioniert'. Das geht deutlich schlanker, würde daher auch mit 1/4 des Codes auskommen (siehe BBCB3).
Zuletzt geändert von BNa am 26.12.2012 20:43, insgesamt 1-mal geändert.
Benutzeravatar
Miriam
Mitglied
Beiträge: 12310
Registriert: 13.10.2004 07:18
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von Miriam »

Code: Alles auswählen

 if (function_exists('url_to_bbvideo'))
    {
    function url_to_bbvideo($text)
    { 
...na mal sehen, was das bringt.
Gruss, Miriam.
Ich schmeiß' alles hin und...
... lasse es liegen
Benutzeravatar
bullydogge88
Mitglied
Beiträge: 81
Registriert: 12.11.2012 08:46
Wohnort: Nrw
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von bullydogge88 »

Es scheint etwas bewirkt zu haben zu haben.
Aber jetzt bekomm ich die Fehlermeldung für die Funktion danach :roll:
Fatal error: Cannot redeclare abbc3_add_all_ed2k_link() (previously declared in /users/hundeforum/www/phpBB3/includes/abbcode.php:2323) in /users/hundeforum/www/phpBB3/includes/abbcode.php on line 2345
http://hundeforum.bplaced.net/phpBB3
Heilir Æsir, heilar Ásynjur
og öll ginnheilög go
Benutzeravatar
bullydogge88
Mitglied
Beiträge: 81
Registriert: 12.11.2012 08:46
Wohnort: Nrw
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von bullydogge88 »

Hab jetzt das jetzt mal bei dem danach folgenden eingefügt und es geht munter weiter.

Werd das mal bei allen nachfolgenden "Funktionen" machen und dann berichten.

Edit: Nö das war wohl nix. Also Fehlermeldung verschob sich immer weiter bis zum Schluß.

Und dann kamm beim Aufrufen der Einstellungen im ACP diese Meldung: Fatal error: Cannot redeclare class abbcode in /users/hundeforum/www/phpBB3/includes/abbcode.php on line 28

Zudem kam die gleiche Meldung beim Aufrufen eines ganz normalen Beitrages,sprich man konnt keine Beiträge mehr lesen.
http://hundeforum.bplaced.net/phpBB3
Heilir Æsir, heilar Ásynjur
og öll ginnheilög go
Benutzeravatar
BNa
Valued Contributor
Beiträge: 3169
Registriert: 12.04.2010 23:51
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von BNa »

Ist ja beim näheren hingucken noch schlimmer als gedacht.

Mache erstmal alle bisherigen Ansätze rückgängig, nimm dir die ModX und dessen Edits vor..

und zwar in der

includes/bbcode.php
includes/functions_content.php
includes/functions_display.php

ersetze

Code: Alles auswählen

include($phpbb_root_path . 'includes/abbcode.' . $phpEx);
mit

Code: Alles auswählen

include_once($phpbb_root_path . 'includes/abbcode.' . $phpEx);
Das sollte es lösen..
Benutzeravatar
bullydogge88
Mitglied
Beiträge: 81
Registriert: 12.11.2012 08:46
Wohnort: Nrw
Kontaktdaten:

Re: Problem mit Advanced BBCode Box 3 Einstellungen

Beitrag von bullydogge88 »

Jetzt hab ich wieder die Fehlermeldung aus meinem ersten Beitrag: Fatal error: Cannot redeclare url_to_bbvideo() (previously declared in /users/hundeforum/www/phpBB3/includes/abbcode.php:2277) in /users/hundeforum/www/phpBB3/includes/abbcode.php on line 2308

Hatte alles wieder rückgängig gemacht und den Vorschlag von BNa ausgeführt,in allen drei Dateien.
http://hundeforum.bplaced.net/phpBB3
Heilir Æsir, heilar Ásynjur
og öll ginnheilög go
Antworten

Zurück zu „[3.0.x] Mod Support“