wie verlinkt man anonym wie hier in RR

Dieses Thema im Forum "Webentwicklung" wurde erstellt von GinGer, 18. Dezember 2005 .

Schlagworte:
Status des Themas:
Es sind keine weiteren Antworten möglich.
  1. 21. Dezember 2005
    Vergiss, was da alles vor mir stand.nemesis87 seiner ist der richtige, aber bin nicht sicher, ob dieser auch für 2.3 funzt, weil eben viele Sachen im Code anders sind.

    Mache folgendes...



    1. Sprachvariable erstellen:
    Kategorie: GLOBAL
    Name: LANG_GLOBAL_REDIR_URL
    Inhalt: Die angeforderte Seite wird aufgerufen. Bitte warten.

    2. redir.php hochladen (hänge ich dran als Text)

    3. öffne ./acp/lib/class_parse.php


    und suche (Zeile 52):
    Code:
    var $useCaching = 0;
    füge danach ein:
    Code:
    var $boardurls = array();
    suche (Zeile 373-384):
    Code:
    function formaturl($url, $title = '', $maxwidth = 60, $width1 = 40, $width2 = -15) {
     if (!wbb_trim($title)) {
     $title = rehtmlconverter($url);
     if (!preg_match("/[a-z]:\/\//si", $url)) $url = "http://$url";
     if ($this->cuturls == 1 && wbb_strlen($title) > $maxwidth) $title = wbb_substr($title, 0, $width1)."...".wbb_substr($title, $width2);
     return "<a href=\"$url\" target=\"_blank\">".htmlconverter(str_replace("\\\"", "\"", $title))."</a>";
     }
     else {
     if (!preg_match("/[a-z]:\/\//si", $url)) $url = "http://$url";
     return "<a href=\"$url\" target=\"_blank\">".$title."</a>";
     }
     }
    ...ersetze dies durch:
    Code:
    function formaturl($url, $title = '', $maxwidth = 60, $width1 = 40, $width2 = -15) {
     global $boardurls;
     $test = str_replace("http://", "", $boardurls);
     $test = preg_replace('!\/(.*)!', '', $test); 
     $this->boardurls = explode("\n",$test);
     if (!wbb_trim($title)) {
     $title = rehtmlconverter($url);
     if (!preg_match("/[a-z]:\/\//si", $url)) $url = "http://$url";
     $host = parse_url($url); 
     $host = $host['host']; 
     if ($this->cuturls == 1 && wbb_strlen($title) > $maxwidth) $title = wbb_substr($title, 0, $width1)."...".wbb_substr($title, $width2);
     if (in_array($host, $this->boardurls)) {
     return "<a href=\"$url\" target=\"_blank\">".htmlconverter(str_replace("\\\"", "\"", $title))."</a>";
     } else {
     return "<a href=\"redir.php?url=".urlencode($url)."\" target=\"_blank\">".htmlconverter(str_replace("\\\"", "\"", $title))."</a>";
     }
     
     }
     else {
     if (!preg_match("/[a-z]:\/\//si", $url)) $url = "http://$url";
     $host = parse_url($url); 
     $host = $host['host']; 
     if (in_array($host, $this->boardurls)) {
     return "<a href=\"$url\" target=\"_blank\">".$title."</a>";
     } else {
     return "<a href=\"redir.php?url=".urlencode($url)."\" target=\"_blank\">".$title."</a>";
     }
     }
     }
    4. Führe folgende Datenbank Abfrage aus:
    Code:
    DELETE FROM bbX_postcache;
    (X durch Boardnummer ersetzen)



    Das war alles....
    Hier brauchst du nichts mehr ändern etc..Ist alles schon fertig.

    Solltest du Probleme beim Einbau haben, kannst mir ne PM schicken, dann mach ich das für dich.

    So, hier noch die redir-Datei.
    Markiere alles und speicher das als redir.php ab.

    Code:
    <?
    $filename="redir.php";
    require("./global.php");
    $lang->load('GLOBAL');
    
    if(isset($_REQUEST['url'])) {
    redirect($lang->get("LANG_GLOBAL_REDIR_URL"), urldecode($_REQUEST['url']), 1);
    exit;
    } else {
     die("syntax beachten");
    }
    
    ?>
    Diese dann in dein WBB Verzeichnis laden.
     
  2. 21. Dezember 2005
    das ist mal ne anleitung
    coole sau danke schön
    10ner geht raus an dich
     
  3. Video Script

    Videos zum Themenbereich

    * gefundene Videos auf YouTube, anhand der Überschrift.