MyBB.de Forum

Normale Version: Portal-Abo
Du siehst gerade eine vereinfachte Darstellung unserer Inhalte. Normale Ansicht mit richtiger Formatierung.
Seiten: 1 2
Eine neue Erweiterung wurde veröffentlicht: Portal-Abo

Zitat:Dieses Plugin zeigt im Portal die abonnierten Themen an.

Verschiedene Einstellungen sind im ACP vorzunehmen.

Installation:
- Datenbankbackup!

- kopiere die Datei "portal_abo.php" in das vorgegebene Verzeichnis:
*/inc/plugins/

- installiere das Plugin im ACP
*ACP/Plugins

- kontrollieren, ob die Variable "{$portal_abo}" im Template "portal" eingetragen ist, oder setze das Template an einer anderen Stelle.
*ACP/Templates & Styles/Templates/Globale Templates/Portal Templates/portal

- Einstellungen über das ACP vornehmen
*ACP/Konfiguration/Portal Einstellungen







Achtung, für ProPortal - Nutzer!
Dieses Plugin ist nicht für ProPortal geschrieben und somit auch nicht kompatibel!

Für die Nutzung im ProPortal bitte nur unten stehende Erweiterung nutzen!

Erweiterung!
Die abonnierte Themen lassen sich nun auch im ProPortal anzeigen.

Kopiere dafür folgende Datei in das dafür vorgesehene Verzeichnis:

block_abothreads.php
root/portal/blocks/

Gehe in die ProPortal - Konfiguration im ACP und wähle das "Block Management"

Füge über die Funktion "Add Block" einen neuen Block hinzu und wähle den "Block File" abothreads!

Speichern und fertig!
Bug gefunden,
wenn man PorPortal nutzt,kann man dieses Plugin nciht benutzen !

mfg
Das ist nicht besonders verwunderlich. Wink
(27.02.2011, 07:52)emink123 schrieb: [ -> ]...,
wenn man PorPortal nutzt,kann man dieses Plugin nciht benutzen !

Im unteren Teil findest Du die Erweiterung für das ProPortal.
hmm... leider wird nur ein abo auf der startseite angezeigt. (proportal)
hat jemand dieses plugin und werden bei ihm mehrere bzw alle abos aufgeführt?
Hallo,
das Plugin habe ich getestet und bei mir funktioniert es. Es läuft allerdings auf einer älteren Foren-Version.
Werde es aber heuteabend mal auf der aktuellen Version testen.
Bis dahin kannst Du Dir in der Datei auf Zeile 25, den Wert mal ansehen, ob dieser stimmt.
PHP-Code:
$abothreadlimit 10
Hallo tomtom.
Vielen dank erstmal für dein feedback.
Ja.... den wert hatte ich mir gestern schon angesehen und dieser steht auf 10.

PHP-Code:
<?php
/***************************************************************
 * ProPortal
 * Copyright � 2010 ProMyBB, All Rights Reserved
 *
 * Website: http://www.promybb.com/
 * License: http://creativecommons.org/licenses/by-nc-sa/3.0/
 * 
 * Expansion created by Thomas Rotner
 * Website: http://www.HundeLexi.de
 * Support: http://www.mybbcoder.info/thema-5217.html
 ***************************************************************/

if (!defined("IN_PORTAL")) {
    die(
"<div style=\"border:1px solid #CC0000; padding:3px; margin:0; font-family:Tahoma; width:250px; font-size:12px;\"><strong>Error:</strong> This file cannot be viewed directly!</div>");
}

$unviewable get_unviewable_forums();
$lang->load("usercp");
if(
$unviewable)
{
    
$unviewwhere " AND fid NOT IN ($unviewable)";
}

$abothreadlimit 10;
$query $db->query("
        SELECT s.*, t.*, t.username AS threadusername, u.username, p.displaystyle AS threadprefix
        FROM "
.TABLE_PREFIX."threadsubscriptions s
        LEFT JOIN "
.TABLE_PREFIX."threads t ON (s.tid=t.tid)
        LEFT JOIN "
.TABLE_PREFIX."users u ON (u.uid = t.uid)
        LEFT JOIN "
.TABLE_PREFIX."threadprefixes p ON (p.pid=t.prefix)
        WHERE s.uid='"
.$mybb->user['uid']."' {$visible}
        ORDER BY t.lastpost DESC
        LIMIT 0, 
$abothreadlimit
    "
);

while(
$thread $db->fetch_array($query)){
    
$query_2 $db->simple_select("forums""fid, name""fid IN (".$thread['fid'].")");
    while(
$forumrow $db->fetch_array($query_2)){
        
$portal_forums $forumrow['name'];
        
$thread['forumlink'] = get_forum_link($thread['fid']);
        
$thread['autorlink'] = get_profile_link($thread['uid']);
    }
    
$query_3 $db->simple_select("threadsread""*""uid='{$mybb->user['uid']}' AND tid IN (".$thread['tid'].")");
    while(
$forumrow $db->fetch_array($query_3)){
        
$thread['lastread'] = $forumrow['dateline'];
    }
    if(
$mybb->settings['dotfolders'] != && $mybb->user['uid']){
        
$query_4 $db->simple_select("posts""tid,uid""uid='{$mybb->user['uid']}' AND tid IN (".$thread['tid'].")");
        while(
$post $db->fetch_array($query_4)){
            
$thread['doticon'] = 1;
        }
    }
    
$folder '';
    
$folder_label '';
    
    if(
$thread['doticon']){
        
$folder "dot_";
        
$folder_label .= $lang->icon_dot;
    }
    
$gotounread '';
    
$isnew 0;
    
$donenew 0;

    if(
$mybb->settings['threadreadcut'] > && $mybb->user['uid'] && $thread['lastpost'] > $forum_read){
        if(
$thread['lastread']){
            
$last_read $thread['lastread'];
        }else{
            
$last_read $read_cutoff;
        }
    }else{
        
$last_read my_get_array_cookie("threadread"$thread['tid']);
    }
    
    if(
$forum_read $last_read){
        
$last_read $forum_read;
    }
        
    if(
$thread['lastpost'] > $last_read && $moved[0] != "moved"){
        
$folder .= "new";
        
$folder_label .= $lang->icon_new;
    }else{
        
$folder_label .= $lang->icon_no_new;
        
$new_class "";
    }
    
    if(
$thread['replies'] >= $mybb->settings['hottopic'] || $thread['views'] >= $mybb->settings['hottopicviews']){
        
$folder .= "hot";
        
$folder_label .= $lang->icon_hot;
    }
    
    if(
$thread['closed'] == 1){
        
$folder .= "lock";
        
$folder_label .= $lang->icon_lock;
    }
    
    if(
$moved[0] == "moved"){
        
$folder "move";
        
$gotounread '';
    }
    
$folder .= "folder";
    
$portal_lastpostdate my_date($mybb->settings['dateformat'], $thread['lastpost']);
    
$portal_lastposttime my_date($mybb->settings['timeformat'], $thread['lastpost']);
    
    if(
$thread['lastposteruid'] == 0){
       
$portal_lastposterlink $thread['lastposter'];
    }else{
       
$portal_lastposterlink build_profile_link($thread['lastposter'], $thread['lastposteruid']);
    }

    if(
my_strlen($thread['subject']) > 50){
       
$thread['subject'] = my_substr($thread['subject'], 050) . "...";
    }
    
$icon_cache $cache->read("posticons");
    
    if(
$thread['icon'] > && $icon_cache[$thread['icon']]){
        
$icon $icon_cache[$thread['icon']];
        
$icon "<img src=\"{$icon['path']}\" alt=\"{$icon['name']}\" />&nbsp;&nbsp;&nbsp;";
    }else{
        
$icon "&nbsp;";
    }
    
$thread['threadlink'] = get_thread_link($thread['tid']);
    
$thread['lastpostlink'] = get_thread_link($thread['tid'], 0"lastpost");
    switch(
$thread['notification']){
       case 
"1":
       
$notification_type $lang->instant_notification;
       break;
       default:
       
$notification_type $lang->no_notification;
    }
    
$query $db->query("
                    SELECT COUNT(ts.tid) as threads
                    FROM "
.TABLE_PREFIX."threadsubscriptions ts
                    LEFT JOIN "
.TABLE_PREFIX."threads t ON (t.tid = ts.tid)
                    WHERE ts.uid = '"
.$mybb->user['uid']."' {$visible}
                "
);
    
$threadcount $db->fetch_field($query"threads");
    
    
$abothreads .= "<tr>
       <td align=\"center\" class=\"
$altbg\" width=\"2%\"><img src=\"$theme[imgdir]/$folder.gif\" alt=\"$folder_label\" title=\"$folder_label\" /></td>
       <td align=\"center\" class=\"
$altbg\" width=\"2%\">$icon</td>
       <td class=\"
$altbg\">$gotounread $thread[threadprefix]&nbsp;&nbsp;&nbsp;<a href=\"$thread[threadlink]\" class=\"$new_class\">$thread[subject]</a><br /><span class=\"smalltext\">$lang->notification_method $notification_type</span></td>
       <td align=\"center\" class=\"
$altbg\">$thread[replies]</a></td>
       <td align=\"center\" class=\"
$altbg\">$thread[views]</td>
       <td class=\"
$altbg\" style=\"white-space: nowrap\">
           <span class=\"smalltext\">
$portal_lastpostdate / $portal_lastposttime<br />
           <a href=\"
$thread[lastpostlink]\">$lang->lastpost</a>: $portal_lastposterlink</span>
       </td>
    </tr>"
;
}

if(!
$abothreads){ 
    
$abothreads "<tr><td class=\"trow1\" colspan=\"5\">{$lang->no_thread}</td></tr>"
}

echo 
"<table border=\"0\" cellspacing=\"".$theme['borderwidth']."\" cellpadding=\"".$theme['tablespace']."\" class=\"tborder\">
        <tr>
            <td class=\"thead\" colspan=\"6\"><div class=\"expcolimage\"><img src=\"
{$theme['imgdir']}/{$expcolimage}\" id=\"block_{$result_blocks['id']}_img\" class=\"expander\" alt=\"{$expaltext}\" title=\"{$expaltext}\" /></div><strong>{$lang->subscriptions}</strong></td>
        </tr>
        <tr>
            <td class=\"tcat\" colspan=\"3\"align=\"center\" width=\"50%\"><span class=\"smalltext\"><strong>
{$lang->thread}</strong></span></td>
            <td class=\"tcat\" align=\"center\" width=\"5%\"><span class=\"smalltext\"><strong>
{$lang->replies}</strong></span></td>
            <td class=\"tcat\" align=\"center\" width=\"5%\"><span class=\"smalltext\"><strong>
{$lang->views}</strong></span></td>
            <td class=\"tcat\" align=\"center\" width=\"40%\"><span class=\"smalltext\"><strong>
{$lang->lastpost}</strong></span></td>
        </tr>
        <tbody style=\"
{$expdisplay}\" id=\"block_{$result_blocks['id']}_e\">
        
{$abothreads}
        </tbody>
    </table>"
;
?>

Der code. Habe nix geändert, meine ich
hier die ansicht im anhang

sind zig foren aboniert, es wird aber nur eins angezeigt

was mir gerade einfällt.... ich habe ja gesamte foren abonniert. funktionierts ggf nur richtig, wenn ich themen abonniere?
Ich hake nochmal vorsichtig nach. Versteht es als ein flüstern.
Dieser Fehler kommt leider auch bei mir. Habe mehr als 10 eingestellt, mehr als 5 abonniert und bekomme aber nur ein Abo angezeiht.

Hab mir eben auch die Erweiterung für das ProPortal eingebaut, leider auch da der selbe Fehler.
Seiten: 1 2