• [MOD] All Comments (Alle Kommentare) V.1.6 5 0 5 1
Currently:  

Author Topic: [MOD] All Comments (Alle Kommentare) V.1.6  (Read 336184 times)

0 Members and 1 Guest are viewing this topic.

Offline mawenzi

  • Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
[MOD] All Comments (Alle Kommentare) V.1.6
« on: December 02, 2005, 02:11:33 AM »
    / - Vorwort / Preface :
    • Diese Art von MOD wurde schon mehrfach im Forum angefragt, so dass ich meine Variante die seit einiger Zeit erfolgreich auf meiner Website läuft, hier als MOD anbiete.
    • Mein Dank geht an Loda, mit dessen Hilfe es zur Umsetzung dieser Version gekommen ist !
    • Dieser MOD läßt sich gut als Erweiterung zu V@no's MOD Last Comments V.1 verwenden, wobei er absolut unabhängig von diesem MOD läuft und so auch unabhängig von diesem auf deiner 4images-Site eingesetzt werden kann.
    • A English MOD-translation is now available !
    • This MOD will show all comments of your website in a list with paging.

    - Demo zum MOD :
    • Gibt es auf meiner Seite zu sehen : hier !
    - MOD-Demo :
    • You can see it on my site : here !

    / - Versionen :
    • 27.10.2009 - "Alle Kategorie-Kommentare" Version 1.6 - als Erweiterung ist online
    • 06.08.2009 - Version 1.6 - "bug fix" Kommentar Counter: Thanks to Sun and V@no
    • 06.08.2009 - Version 1.5 - "bug fix" Gast ohne Profil-Link: Thanks to Schnick und Schnack
    • 17.01.2008 - Version 1.4 - Erweiterung Sprachteil Russisch : Thanks to Valery
    • 29.10.2007 - Version 1.4 - Erweiterung Counter : Kommentare pro Bild. Zu finden hier ...
    • 24.01.2007 - Version 1.3 - Erweiterung Link [Alle Kommentare des Users]. Zu finden hier ...
    • 06.12.2006 - Version 1.3 - "bug fix" der Name des Kommentarschreibers (wenn User) wird als Profillink angezeigt
    • 16.10.2006 - Version 1.2 - Query-Update für php5/mysql5 - danke an Ivan ... hier ... !
    • 14.09.2006 - Version 1.2 - "bug fix" für 4images 1.7.3 - von JinYoshi gepostet ... hier ... thanks ... !
    • 07.09.2006 - Version 1.2 - "bug fix" - $comment_user_info - [Gast]/[Member]/[Administrator] wird jetzt richtig angezeigt !
    • 21.01.2006 - Version 1.1 - Erweiterung {image_user_name}-Tag von V@no incl. "little bug fix"
    • 05.12.2005 - Version 1.0 - English MOD translation
    • 03.12.2005 - Version 1.0 - Einbindung der lang/<deine_Sprache>/main.html
    • 02.12.2005 - Version 1.0 - Admin-Links hinzugefügt
    • 01.12.2005 - Version 1.0 - Veröffentlichung

    - Features zum MOD :
    • Es werden alle für den jeweiligen Besucher (Gast, reg.Benutzer, Admin) zugänglichen Kommentare der Website fortlaufend mit vollem Inhalt und dazugehörigem Thumbnail und weiteren Informationen gelistet angezeigt.
    • Der Besucher kann eine Einstellung vornehmen, wieviel Kommentare er pro Seite angezeigt bekommen möchte.
    • Dementsprechend ist in dem MOD das Paging integriert.
    • Es wird der jeweils letzte Kommentar an erster Stelle angezeigt.
    • Es ist ein Kommentar-Counter integriert, so dass die Kommentare entsprechend der Anzeige absteigend auf jeder Seite fortlaufend nummeriert sind.
    • Der eingeloggte Admin kann direkt über die nur ihm angezeigten Admin-Links die Kommentare bearbeiten. (sehr komfortabel ...)
    • Es lassen sich diverse Einstellungen zur Anpassung an deine Website vornehmen.
    - Features of this MOD :
    • All accessible comments of the website are listed shown for the respective visitor (guest, user, admin) with full contents, with pertinent thumbnail and further informations.  
    • The visitor can adjust, how much comments per page are to be shown.  
    • The Paging is inserted.  
    • The latest comment is shown at the first place of the list.
    • A comment counter is integrated, so that all comments have a sequentially descending number on each page of the list.  
    • The logged in admin can directly edit / delete comments over a link, that is only shown to him. (very comfortably ...)  
    • Various settings can be made for the adjustment of your website.  

    - Voraussetzungen an MODs:
    Um ein korrektes Paging auf den einzelnen Seiten der Kommentar-Liste anzuzeigen, d.h. xx Kommentare statt xx Bilder, solltes du folgende MODs installiert haben :
    - Conditions of MODs :
    In order to show a correct paging on the sides of the comment list, e.g. xx comments instead of xx images, you should have installed the following MODs :

    - Dateien die zu ändern sind :
    - Files to be changed :
    • includes/page_header.php
    • lang/<your_lang>/main.php
    - und je nach Linkeinbindung in deine Templates
    - and for links in you templates e.g.
    • templates/<your_template>/home.html
    • templates/<your_template>/user_logininfo.html
    • templates/<your_template>/user_loginform.html

    - Neue Dateien :
    - New files :
    • comments_all.php
    • templates/<your_template>/comments_all.html
    • templates/<your_template>/comments_all_bit.html
    • templates/<your_template>/commentsperpage_dropdown_form.html

    - Installation :
    WICHTIG: Mache vor der Installation von den zu ändernden Dateien ein Backup.  Nur zur eigenen Sicherheit und nicht dass keiner das Selbstverständliche nochmals erwähnt hätte ... .
    - Installation :
    IMPORTANT: Make a backup of your original files ... .


    - 1. Schritt
    lege im Root-Verzeichnis die neue Datei comments_all.php mit dem folgenden Inhalt an :
    - 1. Step
    in the root directory make a new file comments_all.php with following contents :
    [/list]
    Code: [Select]
    <?php
    /*************************************************************************
    *                                                                        *
    *    4images - A Web Based Image Gallery Management System               *
    *    ----------------------------------------------------------------    *
    *                                                                        *
    *             File: comments_all.php Version 1.6                         *
    *        Copyright: (C) 2002 Jan Sorgalla                                *
    *            Email: jan@4homepages.de                                    *
    *              Web: http://www.4homepages.de                             *
    *    Scriptversion: 1.7.x                                                *
    **************************************************************************
    *    Die comments_all.php ist nicht Bestandteil des Originalscripts !    *
    *    Erstellt durch : mawenzi - www.detlev-kostka.de                     *
    *                   : loda    - www.loda.de ... Danke !                  *
    *                                                                        *
    *************************************************************************/


    $main_template 'comments_all';
    $templates_used 'comments_all_bit';

    define('GET_CACHES'1);
    define('ROOT_PATH''./');
    include(
    ROOT_PATH.'global.php');
    require(
    ROOT_PATH.'includes/sessions.php');
    $user_access get_permission();
    include(
    ROOT_PATH.'includes/page_header.php');

       if (isset(
    $HTTP_POST_VARS['commentsetperpage']) || isset($HTTP_GET_VARS['commentsetperpage'])) {
         
    $commentsetperpage = (intval($HTTP_POST_VARS['commentsetperpage']) ) ? intval($HTTP_POST_VARS['commentsetperpage']) : intval($HTTP_GET_VARS['commentsetperpage']);
         if (
    $commentsetperpage) {
           
    $site_sess->set_session_var("commentperpage"$commentsetperpage);
           
    $session_info['commentperpage'] = $commentsetperpage;
         }
       }

       if (isset(
    $session_info['commentperpage'])) {
         
    $commentperpage $session_info['commentperpage'];
       }
       else {
         
    $commentperpage 10;
       }
       
    $commentsperpage_dropdown "\n<select name=\"commentsetperpage\" onchange=\"if (this.options[this.selectedIndex].value != 0){ forms['commentsperpage'].submit() }\" class=\"select\">\n";
       for(
    $i 1$i <= 20$i++) {
         
    $setvalue $i;
         
    $commentsperpage_dropdown .= "<option value=\"".$setvalue."\"";
           if (
    $setvalue == $commentperpage) {
           
    $commentsperpage_dropdown .= " selected=\"selected\"";
         }
         
    $commentsperpage_dropdown .= ">";
         
    $commentsperpage_dropdown .= $setvalue;
         
    $commentsperpage_dropdown .= "</option>\n";
       }
       
    $commentsperpage_dropdown .= "</select>\n";

       
    $site_template->register_vars("commentsperpage_dropdown"$commentsperpage_dropdown);
       
    $commentsperpage_dropdown_form $site_template->parse_template("commentsperpage_dropdown_form");
       
    $site_template->register_vars("commentsperpage_dropdown_form"$commentsperpage_dropdown_form);

       
    $cat_id_sql get_auth_cat_sql("auth_viewcat""NOTIN").", ".get_auth_cat_sql("auth_readcomment""NOTIN").", ".get_auth_cat_sql("auth_viewimage""NOTIN");

       if (isset(
    $HTTP_GET_VARS['user_id']) and $HTTP_GET_VARS['user_id'] != ""){
        
    $add_where "WHERE c.user_id IN (".$user_id.") AND i.cat_id NOT IN ($cat_id_sql)";
       }else{
        
    $add_where "WHERE i.cat_id NOT IN ($cat_id_sql)";
       }

       
    $sql "SELECT COUNT(*) AS comments
           FROM "
    .COMMENTS_TABLE." c
           LEFT JOIN "
    .IMAGES_TABLE." i ON (i.image_id = c.image_id)
           WHERE i.cat_id NOT IN (
    $cat_id_sql)";
       
    $result $site_db->query_firstrow($sql);
       
    $site_db->free_result();
       
    $num_comments $result['comments'];
       if (
    $action == "postcomment") {
          
    $page ceil($num_comments $commentperpage);
       }
       
    $num_rows_all = (isset($num_comments)) ? $num_comments 0;
       
    $link_arg $site_sess->url(ROOT_PATH."comments_all.php");
       include(
    ROOT_PATH.'includes/paging.php');
       
    $getpaging = new Paging($page$commentperpage$num_rows_all$link_arg$lang['comment_stats'], "comments");
       
    $offset $getpaging->get_offset();
       
    $site_template->register_vars(array(
         
    "paging" => $getpaging->get_paging(),
         
    "paging_stats" => ($num_comments) ? $getpaging->get_paging_stats() : ""
       
    ));

      
    $sql "SELECT c.comment_id, c.image_id, c.user_id, c.user_name AS comment_user_name, c.comment_headline, c.comment_text, c.comment_date".get_user_table_field(", u.""user_level")."
              FROM "
    .COMMENTS_TABLE." c
              LEFT JOIN "
    .USERS_TABLE." u ON (".get_user_table_field("u.""user_id")." = c.user_id)
              LEFT JOIN "
    .IMAGES_TABLE." i ON (i.image_id = c.image_id) ".$add_where."
              ORDER BY c.comment_date DESC
              LIMIT 
    $offset$commentperpage";

      
    $result $site_db->query($sql);
      
    $comment_row = array();
      while (
    $row $site_db->fetch_array($result)) {
        
    $comment_row[] = $row;
      }
      
    $site_db->free_result($result);
      
    $num_comments sizeof($comment_row);
      if (!
    $num_comments) {
        
    $comments_all "<tr><td class=\"commentrow1\" colspan=\"2\">".$lang['no_comments']."</td></tr>";
      }
      else {
        
    $comments_all "";
        
    $ii 1;
        for (
    $i 0$i $num_comments$i++) {
          
    $image_id $comment_row[$i]['image_id'];
          
    $sql "SELECT i.image_id, i.cat_id, i.image_name, c.cat_name, i.image_media_file, i.image_thumb_file".get_user_table_field(", u.""user_id").get_user_table_field(", u.""user_level").get_user_table_field(", u.""user_name")."
                 FROM ("
    .IMAGES_TABLE." i,  ".CATEGORIES_TABLE." c)
                 LEFT JOIN "
    .USERS_TABLE." u ON (".get_user_table_field("u.""user_id")." = i.user_id) 
                 "
    .$add_where."
                 AND i.image_id = "
    .$image_id." AND c.cat_id = i.cat_id ";
          
    $image_row $site_db->query_firstrow($sql);
          
    $cat_id = (isset($image_row['cat_id'])) ? $image_row['cat_id'] : 0;
          
    $comment_counter $num_rows_all-($offset+$i);
          if (
    check_permission("auth_readcomment"$cat_id)){
          
    $comment_user_name htmlspecialchars($comment_row[$i]['comment_user_name']);
          
    $comment_user_id $comment_row[$i]['user_id'];
          
    $user_row_comment get_user_info($comment_user_id);
          
    $comment_user_profile_link "";
          
    $comment_user_info $lang['userlevel_guest'];
            if (!isset(
    $comment_row[$i][$user_table_fields['user_level']]) || (isset($comment_row[$i][$user_table_fields['user_level']]) && $comment_row[$i][$user_table_fields['user_level']] == USER)) {
              
    $comment_user_info $lang['userlevel_user'];
            }
            elseif (
    $comment_row[$i][$user_table_fields['user_level']] == ADMIN) {
              
    $comment_user_info $lang['userlevel_admin'];
            }
         if ( 
    $user_info['user_level'] == GUEST ) {
             
    $comment_user_profile_link "";
          } else {
                 if ( 
    $comment_user_id == -) {
                      
    $comment_user_profile_link "";
                 } else {
                      
    $comment_user_profile_link $site_sess->url(ROOT_PATH."member.php?action=showprofile&amp;user_id=".$comment_user_id);
                 }
          }
          
    $comment_user_link = ($comment_user_profile_link) ? "<a href=\"".$comment_user_profile_link."\">".$comment_user_name."</a>" $comment_user_name;


          if (!
    get_file_path($image_row['image_thumb_file'], "thumb"$image_row['cat_id'], 00)) {
            
    $thumb_file ICON_PATH."/".get_file_extension($image_row['image_media_file']).".gif";
          }else {
            
    $thumb_file get_file_path($image_row['image_thumb_file'], "thumb"$image_row['cat_id'], 01);
          }
          
    $thumb_info = @getimagesize($thumb_file);
          
    $width $thumb_info[0];
          
    $height $thumb_info[1];
          
    $dimension 100;
          
    $ratio $width $height;
          if (
    $ratio 1) {
            
    $new_width $dimension;
            
    $new_height floor(($dimension/$width) * $height);
          }else {
            
    $new_width floor(($dimension/$height) * $width);
            
    $new_height $dimension;
          }
          
    $text $comment_row[$i]['comment_text'];
          
    $text format_text($text$config['html_comments'], $config['wordwrap_comments'], $config['bb_comments'], $config['bb_img_comments']);
          
    $admin_links "";
          if (
    $user_info['user_level'] == ADMIN) {
            
    $admin_links .= "<a href=\"".$site_sess->url(ROOT_PATH."admin/index.php?goto=".urlencode("comments.php?action=editcomment&amp;comment_id=".$comment_row[$i]['comment_id']))."\" target=\"admin_edit\">".$lang['edit']."</a>&nbsp;";
            
    $admin_links .= "<a href=\"".$site_sess->url(ROOT_PATH."admin/index.php?goto=".urlencode("comments.php?action=removecomment&amp;comment_id=".$comment_row[$i]['comment_id']))."\" target=\"admin_edit\">".$lang['delete']."</a>";
          }
          
    $sql "SELECT COUNT(*) AS total_image_comments FROM ".COMMENTS_TABLE." WHERE image_id = ".$image_id."";
               
    $row $site_db->query_firstrow($sql);
               
    $total_image_comments $row['total_image_comments'];

          
    $site_template->register_vars(array(
            
    "total_image_comments" => $total_image_comments,
            
    "comment_counter" => $comment_counter,
            
    "comment_image_thumb" => (!check_permission("auth_viewcat"$cat_id) || !check_permission("auth_viewimage"$cat_id)) ? "<img src=\"".$thumb_file."\" width=\"".$new_width."\" height=\"".$new_height."\" onClick=\"alert('".((isset($lang['auth_alert'][$cat_id])) ? $lang['auth_alert'][$cat_id] : $lang['auth_alert']['default'])."');\" border=\"".$config['image_border']."\">" "<a href=\"".$site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$comment_row[$i]['image_id'].((!empty($mode)) ? "&amp;mode=".$mode ""))."\"><img src=\"".$thumb_file."\" width=\"".$new_width."\" height=\"".$new_height."\" border=\"".$config['image_border']."\"></a>",
            
    "comment_image_name" => (!check_permission("auth_viewcat"$cat_id) || !check_permission("auth_viewimage"$cat_id)) ? $image_row['image_name'] : "<a href=\"".$site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$comment_row[$i]['image_id'].((!empty($mode)) ? "&amp;mode=".$mode ""))."\">".$image_row['image_name']."</a>",
            
    "comment_cat_name" => (!check_permission("auth_viewcat"$cat_id)) ? $image_row['cat_name'] : "<a href=\"".$site_sess->url(ROOT_PATH."categories.php?".URL_CAT_ID."=".$cat_id)."\">".$image_row['cat_name']."</a>",
            
    "comment_user_name" => $comment_user_link,
            
    "comment_user_info" => $comment_user_info,
            
    "comment_headline" => format_text($comment_row[$i]['comment_headline'], 0$config['wordwrap_comments'], 0011),
            
    "comment_text" => format_text($comment_row[$i]['comment_text'], $config['html_comments'], $config['wordwrap_comments'], $config['bb_comments'], $config['bb_img_comments'], 1),
            
    "comment_date" => format_date($config['date_format']." ".$config['time_format'], $comment_row[$i]['comment_date']),
            
    "image_user_name" => ($image_row[$user_table_fields['user_level']] != GUEST) ? "<a href=\"".$site_sess->url(ROOT_PATH."member.php?action=showprofile&amp;user_id=".$image_row[$user_table_fields['user_id']])."\">".htmlspecialchars($image_row[$user_table_fields['user_name']])."</a>" $lang['userlevel_guest'],
            
    "admin_links" => $admin_links,
            
    "lang_variable_text" => $lang['variable_text'],
            
    "lang_navigation" => $lang['navigation'],
            
    "lang_com_per_page" => $lang['com_per_page'],
            
    "lang_com" => $lang['com'],
            
    "lang_for_image" => $lang['for_image'],
            
    "lang_in_cat" => $lang['in_cat'],
            
    "lang_com_date" => $lang['com_date'],
            
    "lang_com_by" => $lang['com_by'],
            
    "lang_com_to_this" => $lang['com_to_this'],
            
    "lang_com_total" => $lang['com_total']
          ));
          
    $comments_all .= $site_template->parse_template("comments_all_bit");
         }
        }
      }
      
    $site_template->register_vars("comments_all"$comments_all);
      unset(
    $comments_all);

    //-----------------------------------------------------
    //--- Clickstream -------------------------------------
    //-----------------------------------------------------
    $clickstream "<span class=\"clickstream\"><a href=\"".$site_sess->url(ROOT_PATH."index.php")."\" class=\"clickstream\">".$lang['home']."</a>".$config['category_separator'].$lang['all_comments']."</span>";
    $site_template->register_vars("clickstream"$clickstream);

    //-----------------------------------------------------
    //--- Print Out ---------------------------------------
    //-----------------------------------------------------
    $site_template->print_template($site_template->parse_template($main_template));
    include(
    ROOT_PATH.'includes/page_footer.php');
    ?>


    - 2. Schritt
    lege im Template-Verzeichnis die neue Datei an :
    /templates/<dein_Template>/comments_all.html
    wobei du eine Kopie deiner :
    /templates/<dein_Template>/error.html
    verwenden solltest, indem du die Datei entsprechend umbenennst und dann den folgenden Code (Beispiel Standard-Template) :
    - 2. Step
    make a new file in the template directory :
    /templates/<your_template>/comments_all.html
    you should make a copy of your :
    /templates/<your_template>/error.html
    with the new name and replace the following contents (example standard-template) :
    Code: [Select]
    <b class="title">{lang_error}</b>
    <hr size="1" />
    <p>{error_msg}</p>

    - durch diesen neuen Code ersetzt (so ist schon mal das umgebene Design deines Templates gewahrt ... !) :
    - by this new code ( design of your template is saved ... !)
    Code: [Select]
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td><span class="title">{lang_all_comments}</span></td>
    <td align="right" valign="bottom">
    </td>
    </tr>
    </table>
    <hr size="1" />
    <br />
    {lang_variable_text}
    <br />
    {if paging}{if paging_stats}
             <table width="100%" border="0" cellspacing="1" cellpadding="0" class="head2">
                <tr>
                   <td>
                      <table width="100%" border="0" cellspacing="0" cellpadding="3">
                         <tr>
                            <td width="65%" class="row1" valign="middle">
                               {paging_stats}
                            </td>
                            <td width="30%" class="row1" valign="middle" align="right">
                               {lang_com_per_page}
                            </td>
                            <td width="5%" class="row1" valign="top" align="right">
                               {commentsperpage_dropdown_form}
                            </td>
                         </tr>
                      </table>
                   </td>
                </tr>
             </table>
          <br />
            <table width="100%" border="0" cellspacing="1" cellpadding="0" class="head2">
                <tr>
                   <td>
                      <table width="100%" border="0" cellspacing="0" cellpadding="3">
                         <tr>
                            <td class="row1" valign="top" align="left">{lang_navigation}</td>
                            <td class="row1" valign="top" align="right">{paging}</td>
                         </tr>
                      </table>
                   </td>
                </tr>
             </table>
          <br />
    {endif paging_stats}{endif paging}
    <br />
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      {comments_all}
    </td></tr></table>
    <br />
    {if paging}
             <table width="100%" border="0" cellspacing="1" cellpadding="0" class="head2">
                <tr>
                   <td>
                      <table width="100%" border="0" cellspacing="0" cellpadding="3">
                         <tr>
                            <td class="row1" valign="top" align="left">{lang_navigation}</td>
                            <td class="row1" valign="top" align="right">{paging}</td>
                         </tr>
                      </table>
                   </td>
                </tr>
             </table>
          <br />
    {endif paging}

    - Die weitere Template-Gestaltung ist natürlich deine Sache .
    In der comments_all.html können die folgenden Tags verwendet werden :
    - Of course is template designing your part.
    The following tags are available to use in comments_all.html :
    {if paging}
    {paging}
    {endif paging}
    {if paging_stats}
    {paging_stats}
    {endif paging_stats}
    {commentsperpage_dropdown_form}
    {comments_all}


    - Und diese Sprach-Tags :
    - And this language-tags :
    {lang_all_comments}
    {lang_variable_text}
    {lang_com_per_page}
    {lang_navigation}


    - Wobei die Bedeutung der Tags selbsterklärend sein dürfte ... .
    - You recognize the meaning of the tags alone ... .

    - 3. Schritt
    lege im Template-Verzeichnis die neue Datei /templates/<dein_Template>/comments_all_bit.html mit folgendem Inhalt an.
    - 3. Step
    in template directory make a new file /templates/<your_template>/comments_all_bit.html with the following contents.
    Code: [Select]
    <tr><td>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr><td class="bordercolor">
    <table width="100%" border="0" cellspacing="1" cellpadding="4">
    <tr>
       <td colspan="2" class="head2" height="20">
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr><td width="75%">
            <b>{comment_counter}. {lang_com}</b> <small>{lang_for_image}</small><b> {comment_image_name}</b> <small>- [{lang_in_cat} {comment_cat_name}]</td>
            <td align="right" width="25%">
            <small>[{lang_com_date} <b>{comment_date}</b>]</small></td>
            </tr></table>
       </td>
    </tr>
    <tr>
       <td width="15%" rowspan="2" class="row2" valign="top" align="center">
             {comment_image_thumb}
             {image_user_name}
       </td>
       <td width="85%" class="row2" valign="top" align="left"><b>{comment_headline}</b>&nbsp;<small>[{lang_com_total} {total_image_comments} {lang_com_to_this}]</small><hr size="1" />{comment_text}<br></td>
    </tr><tr>
       <td class="row1" valign="top">
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr><td width="50%">
            <small>{lang_com_by} : {comment_user_name} [{comment_user_info}]</small></td>
            <td align="right" width="50%">
            <small>{if admin_links}{admin_links}{endif admin_links}</small></td>
            </tr></table>
       </td>
    </tr>
    </td></tr></table>
    </td></tr></table>
    <br>
    </td></tr>

    - Die weitere Template-Gestaltung incl. des Sprachgebrauchs ist natürlich auch hier deine Sache.
    In der comments_all_bit.html können die folgenden Tags verwendet werden :
    - Of course is template designing your part.
    The following tags are available to use in comments_all_bit.html :
    {comment_counter}
    {total_image_comments}
    {comment_image_name}
    {comment_cat_name}
    {comment_date}
    {comment_image_thumb}
    {comment_headline}
    {comment_text}
    {comment_user_name}
    {comment_user_info}
    {image_user_name}
    {if admin_links}
    {admin_links}
    {endif admin_links}


    - Und diese Sprach-Tags :
    - And this language-tags :
    {lang_com}
    {lang_for_image}
    {lang_in_cat}
    {lang_com_date}
    {lang_com_by}
    {lang_com_total}
    {lang_com_to_this}


    - Wobei die Bedeutung der Tags auch hier selbsterklärend sein dürfte ... .
    - You recognize the meaning of the tags alone ... .

    - 4. Schritt
    lege im Template-Verzeichnis die neue Datei /templates/<dein_Template>/commentsperpage_dropdown_form.html mit dem folgenden Inhalt an.
    - 4. Step
    in template directory make a new file /templates/<your_template>/commentsperpage_dropdown_form.html with the following contents.
    Code: [Select]
    <table border="0" cellspacing="0" cellpadding="0">
       <form method="post" action="{self}" name="commentsperpage">
          <tr>
             <td>{commentsperpage_dropdown}</td>
          </tr>
       </form>
    </table>

    - 5. Schritt
    Öffne die Datei includes/page_header.php und finde :
    - 5. Step
    Open the file includes/page_header.php and find :

    "url_home" => $site_sess->url(ROOT_PATH."index.php"),

    - und füge unmittelbar dahinter die folgende Codezeile ein.
    - and insert after the following code.

    "url_comments_all" => $site_sess->url(ROOT_PATH."comments_all.php"),
    "lang_all_comments" => $lang['all_comments'],


    - 6. Schritt
    Öffne die Datei /lang/deutsch/main.php und finde am Ende :
    - 6. Step
    Open the file /lang/<your_lang>/main.php and find at the end :
    Code: [Select]
    ?>

    - und füge unmittelbar davor den folgenden Code ein:

    //-----------------------------------------------------
    //--- [MOD]All Comments / Alle Kommentare -------------
    //-----------------------------------------------------
    $lang['all_comments'] = "Alle Kommentare";
    $lang['no_comments'] = "Keine Kommentare";
    $lang['variable_text'] = "Auf den folgenden Seiten kannst du alle Bild-Kommentare nachlesen.";
    $lang['navigation'] = "Seiten-Navigation :";
    $lang['com_per_page'] = "Kommentare pro Seite :";
    $lang['com'] = "Kommentar";
    $lang['for_image'] = "zum Bild :";
    $lang['in_cat'] = "In Kategorie :";
    $lang['com_date'] = "gepostet am :";
    $lang['com_by'] = "gepostet von :";
    $lang['com_total'] = "gesamt :";
    $lang['com_to_this'] = "Kommentar(e) zu diesem Bild";


    - and insert above the following code :

    //-----------------------------------------------------
    //--- [MOD]All Comments / Alle Kommentare -------------
    //-----------------------------------------------------
    $lang['all_comments'] = "All comments";
    $lang['no_comments'] = "No comments";
    $lang['variable_text'] = "Your individual text for all comments list ...";
    $lang['navigation'] = "Page navigation :";
    $lang['com_per_page'] = "Comments per page :";
    $lang['com'] = "Comment";
    $lang['for_image'] = "to image :";
    $lang['in_cat'] = "In category:";
    $lang['com_date'] = "Date posted :";
    $lang['com_by'] = "Posted by :";
    $lang['com_total'] = "total :";
    $lang['com_to_this'] = "comment(s) to this image";


    - And for Russian language - add in lang/russian/main.php (thanks to Valery) :
    Code: [Select]
    //-----------------------------------------------------
    //--- [MOD]All Comments / Alle Kommentare -------------
    //-----------------------------------------------------
    $lang['all_comments'] = "Все комментарии";
    $lang['no_comments'] = "0 комментарии";
    $lang['variable_text'] = "Список всех комментариев в порядке убывания.";
    $lang['navigation'] = "Выберите категорию:";
    $lang['com_per_page'] = "Комментариев на странице:";
    $lang['com'] = "Комментарий";
    $lang['for_image'] = "фото:";
    $lang['in_cat'] = "Категория:";
    $lang['com_date'] = "дата комментария:";
    $lang['com_by'] = "Ответил:";
    $lang['com_total'] = "всего:";
    $lang['com_to_this'] = "Комментариев на эту работу";

    - 7. Schritt
    Jetzt kannst du an jeder Stelle in deinen Templates den folgenden Tag als Link zu deiner Kommentar-Liste verwenden. Z.B. in deinem Menü (user_logininfo.html , user_loginform.html) oder in einer Zeile unterhalb deiner "Letzten Kommentare" in der home.html.
    - 7. Step
    Now you can use on every place in your templates the following tag as link to your all-comments-list e.g. in your menue (user_logininfo.html , user_loginform.html) or in a line after your "Last Comments" in your home.html.
    Code: [Select]
    <a href="{url_comments_all}">{lang_all_comments}</a>

    - 8. Schritt - Einstellungmöglichkeiten
    Die folgenden Einstellungen lassen sich zur Anpassung an deine Website in der comments_all.php vornehmen:
    • Kommentare pro Seite : Standard = 10 ; Änderung unter - $commentperpage =  10;
    • Min. Kommentare pro Seite : Standard = 1 ; Änderung unter - for($i = 1; $i <=  20;
    • Max. Kommentare pro Seite : Standard = 20 ; Änderung unter - for($i = 1; $i <=  20;
    • Thumbnail-Größe : Standard = 100% ; Änderung unter - $dimension =  100;
    - 8. Step - Settings
    The following settings can be made for the adjustment of your website in comments_all.php :
    • Comments per page : standard = 10 ; change through - $commentperpage =  10;
    • Min. Comments per page : standard = 1 ; change through - for($i = 1; $i <=  20;
    • Max. Comments per page : standard = 20 ; change through - for($i = 1; $i <=  20;
    • Thumbnail-Size : standard = 100% ; change through - $dimension =  100;


    NEU / NEW :

      / - Erweiterung / Extension : Alle Kommentare einer Kategorie / All comments of a category
      • Diese Erweiterung "Alle Kategorie-Kommentare" zeigt alle Kommentare nur einer bestimmten Kategorie analog wie "Alle Kommentare" an.
      • Der Aufruf dieser Seiten erfolgt von der betreffenden Kategorie über den Link "Alle Kategorie-Kommentare".
      • This Extension "All Category-Comments" will show all comments of a certain category analogous "All Comments".
      • The calling of these sites in this category is via a link "All Category-Comments".


      - 1. Schritt
      lege im Root-Verzeichnis die neue Datei comments_cat.php mit dem folgenden Inhalt an :
      - 1. Step
      in the root directory make a new file comments_cat.php with following contents ( please modify for your language ! ) :

      <?php
      /*************************************************************************
      *                                                                        *
      *    4images - A Web Based Image Gallery Management System               *
      *    ----------------------------------------------------------------    *
      *                                                                        *
      *             File: comments_cat.php Version 1.6                         *
      *        Copyright: (C) 2002 Jan Sorgalla                                *
      *            Email: jan@4homepages.de                                    *
      *              Web: http://www.4homepages.de                             *
      *    Scriptversion: 1.7.x                                                *
      **************************************************************************
      *    Die comments_cat.php ist nicht Bestandteil des Originalscripts !    *
      *    Erstellt durch : mawenzi - www.detlev-kostka.de                     *
      *                                                                        *
      *************************************************************************/


      $main_template 'comments_all';
      $templates_used 'comments_all_bit';

      define('GET_CACHES'1);
      define('ROOT_PATH''./');
      include(
      ROOT_PATH.'global.php');
      require(
      ROOT_PATH.'includes/sessions.php');
      $user_access get_permission();
      include(
      ROOT_PATH.'includes/page_header.php');

      $cat_id=$_GET['cat_id'];

         if (isset(
      $HTTP_POST_VARS['commentsetperpage']) || isset($HTTP_GET_VARS['commentsetperpage'])) {
           
      $commentsetperpage = (intval($HTTP_POST_VARS['commentsetperpage']) ) ? intval($HTTP_POST_VARS['commentsetperpage']) : intval($HTTP_GET_VARS['commentsetperpage']);
           if (
      $commentsetperpage) {
             
      $site_sess->set_session_var("commentperpage"$commentsetperpage);
             
      $session_info['commentperpage'] = $commentsetperpage;
           }
         }

         if (isset(
      $session_info['commentperpage'])) {
           
      $commentperpage $session_info['commentperpage'];
         }
         else {
           
      $commentperpage 10;
         }
         
      $commentsperpage_dropdown "\n<select name=\"commentsetperpage\" onchange=\"if (this.options[this.selectedIndex].value != 0){ forms['commentsperpage'].submit() }\" class=\"select\">\n";
         for(
      $i 1$i <= 20$i++) {
           
      $setvalue $i;
           
      $commentsperpage_dropdown .= "<option value=\"".$setvalue."\"";
             if (
      $setvalue == $commentperpage) {
             
      $commentsperpage_dropdown .= " selected=\"selected\"";
           }
           
      $commentsperpage_dropdown .= ">";
           
      $commentsperpage_dropdown .= $setvalue;
           
      $commentsperpage_dropdown .= "</option>\n";
         }
         
      $commentsperpage_dropdown .= "</select>\n";

         
      $site_template->register_vars("commentsperpage_dropdown"$commentsperpage_dropdown);
         
      $commentsperpage_dropdown_form $site_template->parse_template("commentsperpage_dropdown_form");
         
      $site_template->register_vars("commentsperpage_dropdown_form"$commentsperpage_dropdown_form);

         
      $cat_id_sql get_auth_cat_sql("auth_viewcat""NOTIN").", ".get_auth_cat_sql("auth_readcomment""NOTIN").", ".get_auth_cat_sql("auth_viewimage""NOTIN");

         if (isset(
      $HTTP_GET_VARS['user_id']) and $HTTP_GET_VARS['user_id'] != ""){
          
      $add_where "WHERE c.user_id IN (".$user_id.") AND i.cat_id NOT IN ($cat_id_sql)";
         }else{
          
      $add_where "WHERE i.cat_id NOT IN ($cat_id_sql)";
         }

         
      $sql "SELECT COUNT(*) AS comments
             FROM "
      .COMMENTS_TABLE." c
             LEFT JOIN "
      .IMAGES_TABLE." i ON (i.image_id = c.image_id)
             WHERE i.cat_id NOT IN (
      $cat_id_sql)
             AND i.cat_id = "
      .$cat_id."";
         
      $result $site_db->query_firstrow($sql);
         
      $site_db->free_result();
         
      $num_comments $result['comments'];
         if (
      $action == "postcomment") {
            
      $page ceil($num_comments $commentperpage);
         }
         
      $num_rows_all = (isset($num_comments)) ? $num_comments 0;
         
      $link_arg $site_sess->url(ROOT_PATH."comments_cat.php?cat_id=".$cat_id."");
         include(
      ROOT_PATH.'includes/paging.php');
         
      $getpaging = new Paging($page$commentperpage$num_rows_all$link_arg$lang['comment_stats'], "comments");
         
      $offset $getpaging->get_offset();
         
      $site_template->register_vars(array(
           
      "num_comments" => $num_comments,
           
      "paging" => $getpaging->get_paging(),
           
      "paging_stats" => ($num_comments) ? $getpaging->get_paging_stats() : ""
         
      ));

        
      $sql "SELECT c.comment_id, c.image_id, c.user_id, c.user_name AS comment_user_name, c.comment_headline, c.comment_text, c.comment_date".get_user_table_field(", u.""user_level")."
                FROM "
      .COMMENTS_TABLE." c
                LEFT JOIN "
      .USERS_TABLE." u ON (".get_user_table_field("u.""user_id")." = c.user_id)
                LEFT JOIN "
      .IMAGES_TABLE." i ON (i.image_id = c.image_id) ".$add_where."
                AND i.cat_id = "
      .$cat_id."
                ORDER BY c.comment_date DESC
                LIMIT 
      $offset$commentperpage";

        
      $result $site_db->query($sql);
        
      $comment_row = array();
        while (
      $row $site_db->fetch_array($result)) {
          
      $comment_row[] = $row;
        }
        
      $site_db->free_result($result);
        
      $num_comments sizeof($comment_row);
        if (!
      $num_comments) {
          
      $comment_cat_name "<a href=\"".$site_sess->url(ROOT_PATH."categories.php?cat_id=".$cat_id)."\">".htmlspecialchars($cat_cache[$cat_id]['cat_name'])."</a>";
          
      $comments_all "<tr><td colspan=\"2\">Es wurden noch keine Kommentare zu Bildern in der Kategorie ".$comment_cat_name." abgegeben. Mach den Anfang !</td></tr>";
          
      $msg "Sorry - keine Kommentare";
          
      $site_template->register_vars(array(
              
      "msg" => $msg,
              
      "comment_cat_name" => $comment_cat_name
          
      ));
        }
        else {
          
      $comments_all "";
          
      $ii 1;
          for (
      $i 0$i $num_comments$i++) {
            
      $image_id $comment_row[$i]['image_id'];
            
      $sql "SELECT i.image_id, i.cat_id, i.image_name, c.cat_name, i.image_media_file, i.image_thumb_file".get_user_table_field(", u.""user_id").get_user_table_field(", u.""user_level").get_user_table_field(", u.""user_name")."
                   FROM ("
      .IMAGES_TABLE." i,  ".CATEGORIES_TABLE." c)
                   LEFT JOIN "
      .USERS_TABLE." u ON (".get_user_table_field("u.""user_id")." = i.user_id)
                   "
      .$add_where."
                   AND i.image_id = "
      .$image_id." AND c.cat_id = i.cat_id AND c.cat_id = ".$cat_id." ";
            
      $image_row $site_db->query_firstrow($sql);
            
      $cat_id = (isset($image_row['cat_id'])) ? $image_row['cat_id'] : 0;
            
      $comment_counter $num_rows_all-($offset+$i);
            if (
      check_permission("auth_readcomment"$cat_id)){
            
      $comment_user_name htmlspecialchars($comment_row[$i]['comment_user_name']);
            
      $comment_user_id $comment_row[$i]['user_id'];
            
      $user_row_comment get_user_info($comment_user_id);
            
      $comment_user_profile_link "";
            
      $comment_user_info $lang['userlevel_guest'];
              if (!isset(
      $comment_row[$i][$user_table_fields['user_level']]) || (isset($comment_row[$i][$user_table_fields['user_level']]) && $comment_row[$i][$user_table_fields['user_level']] == USER)) {
                
      $comment_user_info $lang['userlevel_user'];
              }
              elseif (
      $comment_row[$i][$user_table_fields['user_level']] == ADMIN) {
                
      $comment_user_info $lang['userlevel_admin'];
              }
           if ( 
      $user_info['user_level'] == GUEST ) {
               
      $comment_user_profile_link "";
            } else {
                   if ( 
      $comment_user_id == -) {
                        
      $comment_user_profile_link "";
                   } else {
                        
      $comment_user_profile_link $site_sess->url(ROOT_PATH."member.php?action=showprofile&amp;user_id=".$comment_user_id);
                   }
            }
            
      $comment_user_link = ($comment_user_profile_link) ? "<a href=\"".$comment_user_profile_link."\">".$comment_user_name."</a>" $comment_user_name;


            if (!
      get_file_path($image_row['image_thumb_file'], "thumb"$image_row['cat_id'], 00)) {
              
      $thumb_file ICON_PATH."/".get_file_extension($image_row['image_media_file']).".gif";
            }else {
              
      $thumb_file get_file_path($image_row['image_thumb_file'], "thumb"$image_row['cat_id'], 01);
            }
            
      $thumb_info = @getimagesize($thumb_file);
            
      $width $thumb_info[0];
            
      $height $thumb_info[1];
            
      $dimension 100;
            
      $ratio $width $height;
            if (
      $ratio 1) {
              
      $new_width $dimension;
              
      $new_height floor(($dimension/$width) * $height);
            }else {
              
      $new_width floor(($dimension/$height) * $width);
              
      $new_height $dimension;
            }
            
      $text $comment_row[$i]['comment_text'];
            
      $text format_text($text$config['html_comments'], $config['wordwrap_comments'], $config['bb_comments'], $config['bb_img_comments']);
            
      $admin_links "";
            if (
      $user_info['user_level'] == ADMIN) {
              
      $admin_links .= "<a href=\"".$site_sess->url(ROOT_PATH."admin/index.php?goto=".urlencode("comments.php?action=editcomment&amp;comment_id=".$comment_row[$i]['comment_id']))."\" target=\"admin_edit\">".$lang['edit']."</a>&nbsp;";
              
      $admin_links .= "<a href=\"".$site_sess->url(ROOT_PATH."admin/index.php?goto=".urlencode("comments.php?action=removecomment&amp;comment_id=".$comment_row[$i]['comment_id']))."\" target=\"admin_edit\">".$lang['delete']."</a>";
            }
            
      $sql "SELECT COUNT(*) AS total_image_comments FROM ".COMMENTS_TABLE." WHERE image_id = ".$image_id."";
                 
      $row $site_db->query_firstrow($sql);
                 
      $total_image_comments $row['total_image_comments'];

            
      $comment_cat_name = (!check_permission("auth_viewcat"$cat_id)) ? $image_row['cat_name'] : "<a href=\"".$site_sess->url(ROOT_PATH."categories.php?".URL_CAT_ID."=".$cat_id)."\">".$image_row['cat_name']."</a>";

            
      $site_template->register_vars(array(
              
      "total_image_comments" => $total_image_comments,
              
      "comment_counter" => $comment_counter,
              
      "comment_image_thumb" => (!check_permission("auth_viewcat"$cat_id) || !check_permission("auth_viewimage"$cat_id)) ? "<img src=\"".$thumb_file."\" width=\"".$new_width."\" height=\"".$new_height."\" onClick=\"alert('".((isset($lang['auth_alert'][$cat_id])) ? $lang['auth_alert'][$cat_id] : $lang['auth_alert']['default'])."');\" border=\"".$config['image_border']."\">" "<a href=\"".$site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$comment_row[$i]['image_id'].((!empty($mode)) ? "&amp;mode=".$mode ""))."\"><img src=\"".$thumb_file."\" width=\"".$new_width."\" height=\"".$new_height."\" border=\"".$config['image_border']."\"></a>",
              
      "comment_image_name" => (!check_permission("auth_viewcat"$cat_id) || !check_permission("auth_viewimage"$cat_id)) ? $image_row['image_name'] : "<a href=\"".$site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$comment_row[$i]['image_id'].((!empty($mode)) ? "&amp;mode=".$mode ""))."\">".$image_row['image_name']."</a>",
              
      "comment_cat_name" => $comment_cat_name,
              
      "comment_user_name" => $comment_user_link,
              
      "comment_user_info" => $comment_user_info,
              
      "comment_headline" => format_text($comment_row[$i]['comment_headline'], 0$config['wordwrap_comments'], 0011),
              
      "comment_text" => format_text($comment_row[$i]['comment_text'], $config['html_comments'], $config['wordwrap_comments'], $config['bb_comments'], $config['bb_img_comments'], 1),
              
      "comment_date" => format_date($config['date_format']." ".$config['time_format'], $comment_row[$i]['comment_date']),
              
      "image_user_name" => ($image_row[$user_table_fields['user_level']] != GUEST) ? "<a href=\"".$site_sess->url(ROOT_PATH."member.php?action=showprofile&amp;user_id=".$image_row[$user_table_fields['user_id']])."\">".htmlspecialchars($image_row[$user_table_fields['user_name']])."</a>" $lang['userlevel_guest'],
              
      "admin_links" => $admin_links,
              
      "lang_variable_text" => $lang['variable_text'],
              
      "lang_navigation" => $lang['navigation'],
              
      "lang_com_per_page" => $lang['com_per_page'],
              
      "lang_com" => $lang['com'],
              
      "lang_for_image" => $lang['for_image'],
              
      "lang_in_cat" => $lang['in_cat'],
              
      "lang_com_date" => $lang['com_date'],
              
      "lang_com_by" => $lang['com_by'],
              
      "lang_com_to_this" => $lang['com_to_this'],
              
      "lang_com_total" => $lang['com_total']
            ));
            
      $comments_all .= $site_template->parse_template("comments_all_bit");
           }
          }
        }
        
      $site_template->register_vars("comments_all"$comments_all);
        unset(
      $comments_all);

      //-----------------------------------------------------
      //--- Clickstream -------------------------------------
      //-----------------------------------------------------
      $txt_clickstream "Alle Kommentare der Kategorie ".$comment_cat_name."";
      $clickstream "<span class=\"clickstream\"><a href=\"".$site_sess->url(ROOT_PATH."index.php")."\" class=\"clickstream\">".$lang['home']."</a>".$config['category_separator'].$txt_clickstream."</span>";
      $site_template->register_vars("clickstream"$clickstream);

      //-----------------------------------------------------
      //--- Print Out ---------------------------------------
      //-----------------------------------------------------
      $site_template->print_template($site_template->parse_template($main_template));
      include(
      ROOT_PATH.'includes/page_footer.php');
      ?>


      - 2. Schritt
      in der Datei categories.php finde :
      - 2. Step
      in file categories.php find :

      "msg" => $msg,

      - und füge danach folgendes hinzu :
      - and add after the following ( please modify for your language ! ) :

      "link_cat_comments" => "<a href=\"".$site_sess->url(ROOT_PATH."comments_cat.php?cat_id=".$cat_id)."\">Alle Kommentare der Kategorie</a>",


      - 3. Schritt
      nun kannst du als Link zu der neuen Seite "Alle Kategorie-Kommentare" in der /templates/<dein_Template>/categories.html den folgenden
      Tag in einsetzten :
      - 3. Step
      now you can use as a link to your new page "All Category-Comments" in /templates/<your_Template>/categories.html the following tag :
      [/list]
      Code: [Select]
      {link_cat_comments}


      mawenzi
      « Last Edit: January 08, 2012, 04:58:23 PM by mawenzi »
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

      Offline Toso

      • Jr. Member
      • **
      • Posts: 65
        • View Profile
        • Lachs & Leder
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #1 on: December 02, 2005, 10:53:52 AM »
      Sehr schöner Mod, hab Ihn direkt eingebunden. Respekt!!!  :mrgreen:

      Ich bekomme jedoch noch eine kleine Fehlermeldung in der Statusleiste des Browsers, wenn den Dropdown für "Kommentare pro Seite" auswähle.

      'forms.commentperpage' ist NULL oder kein Objekt

      Offline WoD

      • Newbie
      • *
      • Posts: 22
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #2 on: December 02, 2005, 03:31:26 PM »
      Thanks a lot!! That's exactly what I was lookin' for :)

      -----

      @Support ;)

      Ich würde gerne den "Alle Kommentare" Link auf die Hauptseite meiner Galerie haben. Wie lautet da die korrekte Verknüpfung?

      Quote
      <tr>
        <td width="100%" align="center" height="20" background="templates\4waters\images\4button.gif" ><a style="text-decoration: none" href="hxxp://www.abc.de/forum">Zum Forum</a></td>
       </tr>

      ACHTUNG: Den Link habe ich verändert ;)

      So sähe bei mir der Link auf der Hauptseite der Galerie aus, der in mein Forum verlinkt. Jetzt möche ich gerne "Alle Kommentare" auch so verlinken.
      What to do?

      Grüße
      WoD


      Offline impss

      • Sr. Member
      • ****
      • Posts: 382
        • View Profile
        • Cusstom.net
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #3 on: December 02, 2005, 03:35:04 PM »
      Can't wait for the english version  :mrgreen:

      Offline mawenzi

      • Moderator
      • 4images Guru
      • *****
      • Posts: 4.500
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #4 on: December 02, 2005, 04:15:05 PM »
      @ all - Danke für das schnelle Feedback / Thanks for the fast feedback !

      @Toso,
      habe den 4.Schritt überarbeitet. Bitte aktualisiere deine commentsperpage_dropdown_form.html. Habe nach meiner Anleitung nochmals eine Installation an einer frischen 4images-Installation vorgenommen. Läuft jetzt fehlerfrei bis auf einige optische/gestalterische Änderungen, die ich noch vornehmen werde.

      @WoD,
      deine Frage ist eigentlich mit dem 6.Schritt erklärt und beantwortet ... aber nochmals für deinen Fall ...
      der Link mit Button für deine Hauptseite muss nach deiner Vorlage so aussehen :
      Code: [Select]
      <tr>
       <td width="100%" align="center" height="20" background="templates\4waters\images\4button.gif" ><a style="text-decoration: none" href="{url_comments_all}">Alle Kommentare</a></td>
       </tr>
      Voraussetzung ist natürlich, dass du den Link entsprechend 5.Schritt in der page_header.php registriert hast. Der Link funktioniert dann in allen deinen Templates.

      @ impss,
      After finely MOD-tuning I will begin immediately with the translation ...  :wink:

      mawenzi
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

      Offline JensF

      • Addicted member
      • ******
      • Posts: 1.028
        • View Profile
        • http://www.terraristik-galerie.de
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #5 on: December 02, 2005, 04:15:30 PM »
      @WoD

      ändere das
      Quote
      a style="text-decoration: none" href="hxxp://www.abc.de/forum">Zum Forum</a>
      in das
      Quote
      <a href="{url_comments_all}"><b>Alle Kommentare</b></a>

      @mawenzi

      Vielen herzlichen Dank für diesen Mod. Habe ihn eingebaut und er funktioniert wunderbar aber ich habe noch einige Fragen ;)

      Du schreibst das man als Admin Links zum löschen und bearbeiten der Kommentare hat. Ich sehe leider keine :(
      Und dann wollte ich fragen ob man das noch so erweitern kann das man, wenn gewünscht, nicht die letzten Kommentare sondern die ersten Kommentare sehen kann (ASC-DESC).
      Und ob es möglich ist eine Antwortfunktion einzubauen. Man kann direkt auf den Kommentar antworten von der Liste aus. Natürlich nur wenn man die Rechte dazu hat.
      Mit freundlichem Gruß
      Jens Funk



      -> Sorry for my bad English <-

      Offline impss

      • Sr. Member
      • ****
      • Posts: 382
        • View Profile
        • Cusstom.net
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #6 on: December 02, 2005, 04:29:25 PM »
      Thanks mawenzi  8)

      Offline mawenzi

      • Moderator
      • 4images Guru
      • *****
      • Posts: 4.500
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #7 on: December 02, 2005, 04:31:58 PM »
      @ JensF,

      habe nach einer MOD-Installation in einer Fresh-4-images-Version (siehe oben) den Fehler mit den Admin-Links auch bemerkt. Das ist das Problem, wenn man eine Modifizierung seiner eigenen Website veröffentlicht, dann auch alle relevanten Änderungen dazu in dem veröffentlichten MOD mit einzubauen.
      Werde dieses zugesagte Feature natürlich noch nachreichen ! Die Option (ASC-DESC) hatte ich auch schon integriert ... kein Thema ... muss dann nur den Kommentar-Counter nochmals ändern, da er ja dann auch anders herum zählen muss ... d.h. Nr.1 an erster Stelle .
      Die Option der Antwortmöglichkeit sehe ich eigentlich über den Link zum Bild und dem dort vorhandenen Kommentar-Form gegeben. Oder sollte sich nach deiner Vorstellung nur ein Kommentar-Form öffnen ?

      mawenzi
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

      Offline JensF

      • Addicted member
      • ******
      • Posts: 1.028
        • View Profile
        • http://www.terraristik-galerie.de
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #8 on: December 02, 2005, 04:38:14 PM »
      Hi,

      eigentlich hast du recht mit der Antwortfunktion. Man hat ja den Link zum Bild. Das sollte reichen. Und über die anderen Sachen würde ich mich natürlich freuen :)

      Habe mal ne andere Frage.

      Habe den Link zu den Kommentaren so geändert

      Quote
      <a href="{url_comments_all}">{lang_last_comments}</a>

      Habe diesen Link in der home.html sowie in der user_logininfo.html & user_loginform.html

      Wenn ich meine index.php aufrufe wird mir der Link auch ohne Probleme angezeigt aber wenn ich andere Seiten öffne (z.b. ein Bild anklicke) dann geht der Link nicht mehr....Hast du da ne Idee???
      Mit freundlichem Gruß
      Jens Funk



      -> Sorry for my bad English <-

      Offline mawenzi

      • Moderator
      • 4images Guru
      • *****
      • Posts: 4.500
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #9 on: December 02, 2005, 04:44:15 PM »
      @ JensF,

      hast du den Tag {lang_last_comments} in der page_header.php registriert ... oder nur in der index.php ... ?
      (werde die Integration der /lang/.../main.php wie angekündigt noch vornehmen ... )
      PS. ... der MOD sieht gut aus auf deiner Seite ...   :D

      mawenzi
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

      Offline JensF

      • Addicted member
      • ******
      • Posts: 1.028
        • View Profile
        • http://www.terraristik-galerie.de
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #10 on: December 02, 2005, 05:05:11 PM »
      Quote
      hast du den Tag {lang_last_comments} in der page_header.php registriert ... oder nur in der index.php ... ?

      das war es. jetzt klappt alles.

      danke.....
      Mit freundlichem Gruß
      Jens Funk



      -> Sorry for my bad English <-

      Offline mawenzi

      • Moderator
      • 4images Guru
      • *****
      • Posts: 4.500
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #11 on: December 02, 2005, 05:46:25 PM »
      @ JensF und alle die den MOD bereits installiert haben ... ,

      habe die Admin-Links zum Bearbeiten und Löschen der Kommentare in der comments_all.php nachgerüstet. Diese Datei ist oben aktualisiert worden ... bitte einfach noch mal austauschen !

      @Jako,

      das sieht nach einem prizipiellen Problem mit deiner Paging-Class aus. Funktioniert dein Paging sonst einwandfrei ? Hast du die o.g. Universal-Paging-Class V.1.1 installiert ?

      mawenzi
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

      Offline Jako

      • Newbie
      • *
      • Posts: 46
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #12 on: December 02, 2005, 06:05:54 PM »
      hab den fehler schon gefunden, danke

      Offline dosensteck

      • Full Member
      • ***
      • Posts: 160
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #13 on: December 02, 2005, 09:24:31 PM »
      und der mod hätte nicht 2 wochen früher gepostet werden können? :D

      ich hab mir das selbst gebaut (mit v@nos mod) - http://www.hobby-fotografen.com/comments.php
      werde aber warscheinlich auf deinen mod umstellen da das paging bei mir nicht richtig funktioniert (klick mal auf letzte seite)

      nungut - danke, werde warscheinlich deinen einarbeiten :)

      Offline mawenzi

      • Moderator
      • 4images Guru
      • *****
      • Posts: 4.500
        • View Profile
      Re: [MOD] All Comments (Alle Kommentare) V.1.0
      « Reply #14 on: December 03, 2005, 12:17:34 AM »
      @ dosensteck,

      ... tja ... vor  2 Wochen hat ich diesen MOD auch schon zu laufen ...  :wink:
      Aber gegen ein gutes Paging incl. Paging-Stats sowie einen Kommentar-Counter ist ja auch nichts einzuwenden ...  :mrgreen:

      Es sind halt immer noch 2 verschiedene Dinge ... eine Modifikation auf der eigenen Website zum Laufen zu bekommen und auf der anderen Seite einen MOD hier im Forum zu publizieren, den dann auch alle nachvollziehen und allgemein installieren können.

      Dann versuche es mit meiner Variante ...  :D

      mawenzi
      Your first three "must do" before you ask a question ! ( © by V@no )
      - please read the Forum Rules ...
      - please study the FAQ ...
      - please try to Search for your answer ...

      You are on search for top 4images MOD's ?
      - then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...