[ABD] "Like" Mod

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
plasmino
Registered User
Posts: 261
Joined: Sat Jul 25, 2009 11:12 am

Re: [DEV] "Like" Mod

Post by plasmino » Sun Jan 02, 2011 5:09 pm

wow fantastic mod.. is possible add this mod for profile user?

to say the profile of a member we like

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Sun Jan 02, 2011 5:51 pm

plasmino wrote:wow fantastic mod.. is possible add this mod for profile user?

to say the profile of a member we like
That is not the intended design of the mod, however you could easily modify the mod to support this.
Once I am done with the core features of the mod I will think about adding this as well.

Pete
DigiOz Multimedia
http://www.digioz.com

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Sun Jan 02, 2011 5:52 pm

Gino wrote:wow. it's work.
fantastic..

mmmm
features..
* username color in like list..
* add dislike button appear after pressing like button..
* enable\disable Mod in ACP
;) :oops: :oops:
thanks again .. :oops:
Excellent list of suggestions. I will add them to my queue.

Pete
DigiOz Multimedia
http://www.digioz.com

User avatar
Locou
Registered User
Posts: 80
Joined: Wed Apr 30, 2008 11:47 am
Location: Germany

Re: [DEV] "Like" Mod

Post by Locou » Mon Jan 03, 2011 8:49 am

This mod looks great. I'm going to add it to my board, when the core features are done. :)

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Mon Jan 03, 2011 6:12 pm

Code which provides a link on index page to add a list view containing the most liked threads based on user permissions (first draft, unfinished):
  • Open ./language/en/common.php
  • Find the following line:

    Code: Select all

    	'SEARCH_UNREAD'				=> 'View unread posts',
    
  • Below it add the following:

    Code: Select all

    	'MOST_LIKED_TOPICS'			=> 'Most Liked Topics',
    
  • Open the file "./styles/prosilver/template/index_body.html".
  • Find this file:

    Code: Select all

    <li><a href="{U_SEARCH_UNANSWERED}">{L_SEARCH_UNANSWERED}</a><!-- IF S_LOAD_UNREADS --> &bull; <a href="{U_SEARCH_UNREAD}">{L_SEARCH_UNREAD}</a><!-- ENDIF --><!-- IF S_USER_LOGGED_IN --> &bull; <a href="{U_SEARCH_NEW}">{L_SEARCH_NEW}</a><!-- ENDIF --> &bull; <a href="{U_SEARCH_ACTIVE_TOPICS}">{L_SEARCH_ACTIVE_TOPICS}</a></li>
    
  • Below it, add the following:

    Code: Select all

    		&bull; <li><a href="likedlist.php">{L_MOST_LIKED_TOPICS}</a></li>
    
  • Open the file "./includes/functions_display.php".
  • Find this line:

    Code: Select all

    ?>
    
  • Above it, add the following function:

    Code: Select all

    function get_liked_list($start = 0, $end = false)
    {
        global $db, $config, $auth;
        
        $ex_fid_ary = array_keys($auth->acl_getf('!f_read', true));
        
        $sql = "SELECT A.topic_id,
                    COUNT(A.topic_id) as count,
                    B.forum_id,
                    B.topic_type,
                    B.topic_replies_real,
                    B.topic_replies,
                    B.topic_status,
                    B.topic_moved_id,
                    B.topic_last_post_time,
                    B.topic_approved,
                    B.topic_poster,
                    B.topic_first_poster_name,
                    B.topic_time,
                    B.topic_last_post_subject,
                    B.topic_last_post_time,
                    B.topic_last_poster_id,
                    B.topic_views,
                    B.topic_title,
                    B.icon_id,
                    B.topic_attachment,
                    B.topic_first_poster_name,
                    B.topic_last_post_id,
                    B.topic_last_poster_id,
                    B.topic_last_poster_name,
                    B.topic_last_poster_colour,
                    B.topic_last_post_subject,
                    B.topic_last_post_time,
                    B.topic_last_view_time
                FROM phpbb_likes as A, phpbb_topics AS B WHERE A.topic_id=B.topic_id ".            
                ((sizeof($ex_fid_ary)) ? ' AND ' . $db->sql_in_set('B.forum_id', $ex_fid_ary, true) : '') .
                "GROUP BY A.topic_id ORDER BY count DESC LIMIT 50;";
                
        /*if(!($result = $db->sql_query_limit($sql, $end, $start)))
        {
            message_die(GENERAL_ERROR, 'Error retrieving search results', '', __LINE__, __FILE__, $sql);
        }*/
        
        $result = $db->sql_query($sql);
        
        $result_set = $db->sql_fetchrowset($result);
    
        return $result_set;   
    }
    
  • Add the following new file at "./likedlist.php" with the following content:

    Code: Select all

    <?php
    define('IN_PHPBB', true);
    $phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './';
    $phpEx = substr(strrchr(__FILE__, '.'), 1);
    include($phpbb_root_path . 'common.' . $phpEx);
    include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
    include($phpbb_root_path . 'includes/bbcode.' . $phpEx);
    
    $icons = $cache->obtain_icons();
    
    // Start session management
    $user->session_begin();
    $auth->acl($user->data);
    
    $user->setup();
    //$user->setup('viewtopic'); // for specific template
    
    // If Page access limited to logged in users also add this
    if ($user->data['user_id'] == ANONYMOUS)
    {
        login_box('', $user->lang['LOGIN']);
    }
    
    // Run Query to get list ----------------------------------------------------
    
    $start = request_var('start', 0);
    $result_set = get_liked_list($start);
    
    foreach ($result_set as $row)
                    {
                        $topic_id = $row['topic_id'];
                        $forum_id = $row['forum_id'];
    
                        // This will allow the style designer to output a different header
                        // or even separate the list of announcements from sticky and normal topics
                        $s_type_switch_test = ($row['topic_type'] == POST_ANNOUNCE || $row['topic_type'] == POST_GLOBAL) ? 1 : 0;
    
                        // Replies
                        $replies = ($auth->acl_get('m_approve', $forum_id)) ? $row['topic_replies_real'] : $row['topic_replies'];
    
                        if ($row['topic_status'] == ITEM_MOVED)
                        {
                            $topic_id = $row['topic_moved_id'];
                            $unread_topic = false;
                        }
                        else
                        {
                            $unread_topic = (isset($topic_tracking_info[$topic_id]) && $row['topic_last_post_time'] > $topic_tracking_info[$topic_id]) ? true : false;
                        }
    
                        // Get folder img, topic status/type related information
                        $folder_img = $folder_alt = $topic_type = '';
                        topic_status($row, $replies, $unread_topic, $folder_img, $folder_alt, $topic_type);
    
                        // Generate all the URIs ...
                        $view_topic_url = append_sid("{$phpbb_root_path}viewtopic.$phpEx", 'f=' . (($row['forum_id']) ? $row['forum_id'] : $forum_id) . '&t=' . $topic_id);
    
                        $topic_unapproved = (!$row['topic_approved'] && $auth->acl_get('m_approve', $forum_id)) ? true : false;
                        $posts_unapproved = ($row['topic_approved'] && $row['topic_replies'] < $row['topic_replies_real'] && $auth->acl_get('m_approve', $forum_id)) ? true : false;
                        $u_mcp_queue = ($topic_unapproved || $posts_unapproved) ? append_sid("{$phpbb_root_path}mcp.$phpEx", 'i=queue&mode=' . (($topic_unapproved) ? 'approve_details' : 'unapproved_posts') . "&t=$topic_id", true, $user->session_id) : '';
    
    
    
                        $template->assign_block_vars('topicrow', array(
                            'FORUM_ID'                    => $forum_id,
                            'TOPIC_ID'                    => $topic_id,
                            'TOPIC_AUTHOR'                => get_username_string('username', $row['topic_poster'], $row['topic_first_poster_name']),
                            'TOPIC_AUTHOR_COLOUR'        => get_username_string('colour', $row['topic_poster'], $row['topic_first_poster_name']),
                            'TOPIC_AUTHOR_FULL'            => get_username_string('full', $row['topic_poster'], $row['topic_first_poster_name']),
                            'FIRST_POST_TIME'            => $user->format_date($row['topic_time']),
                            'LAST_POST_SUBJECT'            => censor_text($row['topic_last_post_subject']),
                            'LAST_POST_TIME'            => $user->format_date($row['topic_last_post_time']),
                            'LAST_VIEW_TIME'            => $user->format_date($row['topic_last_view_time']),
                            'LAST_POST_AUTHOR'            => get_username_string('username', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']),
                            'LAST_POST_AUTHOR_COLOUR'    => get_username_string('colour', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']),
                            'LAST_POST_AUTHOR_FULL'        => get_username_string('full', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']),
                            'LIKE_COUNT'                =>  $row['count'],
    
                            'PAGINATION'        => topic_generate_pagination($replies, $view_topic_url),
                            'REPLIES'            => $replies,
                            'VIEWS'                => $row['topic_views'],
                            'TOPIC_TITLE'        => censor_text($row['topic_title']),
                            'TOPIC_TYPE'        => $topic_type,
    
                            'TOPIC_FOLDER_IMG'        => $user->img($folder_img, $folder_alt),
                            'TOPIC_FOLDER_IMG_SRC'    => $user->img($folder_img, $folder_alt, false, '', 'src'),
                            'TOPIC_FOLDER_IMG_ALT'    => $user->lang[$folder_alt],
                            'TOPIC_ICON_IMG'        => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['img'] : '',
                            'TOPIC_ICON_IMG_WIDTH'    => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['width'] : '',
                            'TOPIC_ICON_IMG_HEIGHT'    => (!empty($icons[$row['icon_id']])) ? $icons[$row['icon_id']]['height'] : '',
                            'ATTACH_ICON_IMG'        => ($auth->acl_get('u_download') && $auth->acl_get('f_download', $forum_id) && $row['topic_attachment']) ? $user->img('icon_topic_attach', $user->lang['TOTAL_ATTACHMENTS']) : '',
                            'UNAPPROVED_IMG'        => ($topic_unapproved || $posts_unapproved) ? $user->img('icon_topic_unapproved', ($topic_unapproved) ? 'TOPIC_UNAPPROVED' : 'POSTS_UNAPPROVED') : '',
    
                            
    
                            'S_TOPIC_TYPE'            => $row['topic_type'],
                            'S_USER_POSTED'            => (isset($row['topic_posted']) && $row['topic_posted']) ? true : false,
                            'S_UNREAD_TOPIC'        => $unread_topic,
                            'S_TOPIC_REPORTED'        => (!empty($row['topic_reported']) && $auth->acl_get('m_report', $forum_id)) ? true : false,
                            'S_TOPIC_UNAPPROVED'    => $topic_unapproved,
                            'S_POSTS_UNAPPROVED'    => $posts_unapproved,
                            'S_HAS_POLL'            => (isset($row['poll_start']) && $row['poll_start'])  ? true : false,
                            'S_POST_ANNOUNCE'        => ($row['topic_type'] == POST_ANNOUNCE) ? true : false,
                            'S_POST_GLOBAL'            => ($row['topic_type'] == POST_GLOBAL) ? true : false,
                            'S_POST_STICKY'            => ($row['topic_type'] == POST_STICKY) ? true : false,
                            'S_TOPIC_LOCKED'        => ($row['topic_status'] == ITEM_LOCKED) ? true : false,
                            'S_TOPIC_MOVED'            => ($row['topic_status'] == ITEM_MOVED) ? true : false,
    
                            'U_NEWEST_POST'            => $view_topic_url . '&view=unread#unread',
                            'U_LAST_POST'            => $view_topic_url . '&p=' . $row['topic_last_post_id'] . '#p' . $row['topic_last_post_id'],
                            'U_LAST_POST_AUTHOR'    => get_username_string('profile', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']),
                            'U_TOPIC_AUTHOR'        => get_username_string('profile', $row['topic_poster'], $row['topic_first_poster_name']),
                            'U_VIEW_TOPIC'            => append_sid("{$phpbb_root_path}viewtopic.$phpEx", 'f=' . $forum_id . '&t=' . $topic_id),
                            'U_MCP_REPORT'            => append_sid("{$phpbb_root_path}mcp.$phpEx", 'i=reports&mode=reports&f=' . $forum_id . '&t=' . $topic_id, true, $user->session_id),
                            'U_MCP_QUEUE'            => $u_mcp_queue,
                            'S_TOPIC_TYPE_SWITCH'    => ($s_type_switch == $s_type_switch_test) ? -1 : $s_type_switch_test)
                        );
    
                        $s_type_switch = ($row['topic_type'] == POST_ANNOUNCE || $row['topic_type'] == POST_GLOBAL) ? 1 : 0;
                    }
                    $template->assign_vars(array(
                        'PAGINATION'    => generate_pagination(append_sid("{$phpbb_root_path}likedlist.$phpEx"), $topics_count, $config['topics_per_page'], $start),
                        'PAGE_NUMBER'    => on_page($topics_count, $config['topics_per_page'], $start),
                        'TOTAL_TOPICS'    => (true) ? false : (($topics_count == 1) ? $user->lang['PTT_NUM_TOPIC'] : sprintf($user->lang['PTT_NUM_TOPICS'], $topics_count)),
                        'S_DISPLAY_SEARCHBOX'        => true,
                        )
                    );
                
    // END Query to get list -----------------------------------------------------
    
    page_header('Liked List');
    
    $template->set_filenames(array(
        'body' => 'likedlist_body.html',
    ));
    
    make_jumpbox(append_sid("{$phpbb_root_path}viewforum.$phpEx"));
    page_footer();
    ?>
    
  • Add the following new file "./styles/prosilver/template/likedlist_body.html" with the following content:

    Code: Select all

    <!-- INCLUDE overall_header.html -->
    <h2>LIKED LIST</h2>
    
    <!-- IF S_DISPLAY_POST_INFO or PAGINATION or TOTAL_POSTS or TOTAL_TOPICS -->
    
        <!-- IF PAGINATION or TOTAL_POSTS or TOTAL_TOPICS -->
            <div class="pagination">
                <!-- IF not S_IS_BOT and U_MARK_TOPICS --><a href="{U_MARK_TOPICS}" accesskey="m">{L_MARK_TOPICS_READ}</a> &bull; <!-- ENDIF --><!-- IF TOTAL_TOPICS -->{TOTAL_TOPICS}<!-- ENDIF -->
                <!-- IF PAGE_NUMBER -->
                    <!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF -->
                <!-- ENDIF -->
            </div>
        <!-- ENDIF -->
    
    <!-- ENDIF -->
    <br />
    <!-- IF S_NO_READ_ACCESS -->
    
        <div class="panel">
            <div class="inner"><span class="corners-top"><span></span></span>
            <strong>{L_NO_READ_ACCESS}</strong>
            <span class="corners-bottom"><span></span></span></div>
        </div>
    
        <!-- IF not S_USER_LOGGED_IN -->
    
            <form action="{S_LOGIN_ACTION}" method="post">
    
            <div class="panel">
                <div class="inner"><span class="corners-top"><span></span></span>
    
                <div class="content">
                    <h3><a href="{U_LOGIN_LOGOUT}">{L_LOGIN_LOGOUT}</a>&nbsp; &bull; &nbsp;<a href="{U_REGISTER}">{L_REGISTER}</a></h3>
            
                    <fieldset class="fields1">
                    <dl>
                        <dt><label for="username">{L_USERNAME}:</label></dt>
                        <dd><input type="text" tabindex="1" name="username" id="username" size="25" value="{USERNAME}" class="inputbox autowidth" /></dd>
                    </dl>
                    <dl>
                        <dt><label for="password">{L_PASSWORD}:</label></dt>
                        <dd><input type="password" tabindex="2" id="password" name="password" size="25" class="inputbox autowidth" /></dd>
                        <!-- IF S_AUTOLOGIN_ENABLED --><dd><label for="autologin"><input type="checkbox" name="autologin" id="autologin" tabindex="3" /> {L_LOG_ME_IN}</label></dd><!-- ENDIF -->
                        <dd><label for="viewonline"><input type="checkbox" name="viewonline" id="viewonline" tabindex="4" /> {L_HIDE_ME}</label></dd>
                    </dl>
                    <dl>
                        <dt>&nbsp;</dt>
                        <dd><input type="submit" name="login" tabindex="5" value="{L_LOGIN}" class="button1" /></dd>
                    </dl>
                    </fieldset>
                </div>
    
                <span class="corners-bottom"><span></span></span></div>
            </div>
    
        <!-- ENDIF -->
    
    <!-- ENDIF -->
    
    <!-- BEGIN topicrow -->
        
        <!-- IF not topicrow.S_TOPIC_TYPE_SWITCH and not topicrow.S_FIRST_ROW -->
            </ul>
            <span class="corners-bottom"><span></span></span></div>
        </div>
        <!-- ENDIF -->
    
        <!-- IF topicrow.S_FIRST_ROW or not topicrow.S_TOPIC_TYPE_SWITCH -->
            <div class="forumbg<!-- IF topicrow.S_TOPIC_TYPE_SWITCH --> announcement<!-- ENDIF -->">
            <div class="inner"><span class="corners-top"><span></span></span>
            <ul class="topiclist">
                <li class="header">
                    <dl class="icon">
                        <dt><!-- IF S_DISPLAY_ACTIVE -->{L_ACTIVE_TOPICS}<!-- ELSEIF topicrow.S_TOPIC_TYPE_SWITCH and topicrow.S_TOPIC_TYPE gt 1 -->{L_ANNOUNCEMENTS}<!-- ELSE -->{L_TOPICS}<!-- ENDIF --></dt>
                        <dd class="likes">LIKES</dd>
                        <dd class="posts">{L_REPLIES}</dd>
                        <dd class="views">{L_VIEWS}</dd>
                        <dd class="lastpost"><span>{L_LAST_POST}</span></dd>
                    </dl>
                </li>
            </ul>
            <ul class="topiclist topics">
        <!-- ENDIF -->
        
            <li class="row<!-- IF topicrow.S_ROW_COUNT is even --> bg1<!-- ELSE --> bg2<!-- ENDIF --><!-- IF topicrow.S_POST_ANNOUNCE --> announce<!-- ENDIF --><!-- IF topicrow.S_POST_STICKY --> sticky<!-- ENDIF --><!-- IF topicrow.S_TOPIC_REPORTED --> reported<!-- ENDIF -->">
                <dl class="icon" style="background-image: url({topicrow.TOPIC_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
                    <dt style="<!-- IF topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS -->background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;<!-- ENDIF -->" title="{topicrow.TOPIC_FOLDER_IMG_ALT}"><!-- IF topicrow.S_UNREAD_TOPIC --><a href="{topicrow.U_NEWEST_POST}">{NEWEST_POST_IMG}</a> <!-- ENDIF --><a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
                        <!-- IF topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED --><a href="{topicrow.U_MCP_QUEUE}">{topicrow.UNAPPROVED_IMG}</a> <!-- ENDIF -->
                        <!-- IF topicrow.S_TOPIC_REPORTED --><a href="{topicrow.U_MCP_REPORT}">{REPORTED_IMG}</a><!-- ENDIF --><br />
                        <!-- IF topicrow.PAGINATION --><strong class="pagination"><span>{topicrow.PAGINATION}</span></strong><!-- ENDIF -->
                        <!-- IF topicrow.ATTACH_ICON_IMG -->{topicrow.ATTACH_ICON_IMG} <!-- ENDIF -->{L_POST_BY_AUTHOR} {topicrow.TOPIC_AUTHOR_FULL} {L_POSTED_ON_DATE} {topicrow.FIRST_POST_TIME}<br />
                    </dt>
                    <dd class="likes">{topicrow.LIKE_COUNT} </dd>
                    <dd class="posts">{topicrow.REPLIES} <dfn>{L_REPLIES}</dfn></dd>
                    <dd class="views">{topicrow.VIEWS} <dfn>{L_VIEWS}</dfn></dd>
                    <dd class="lastpost"><span><dfn>{L_LAST_POST} </dfn>{L_POST_BY_AUTHOR} {topicrow.LAST_POST_AUTHOR_FULL}
                        <a href="{topicrow.U_LAST_POST}">{LAST_POST_IMG}</a> <br />{L_POSTED_ON_DATE} {topicrow.LAST_POST_TIME}</span>
                    </dd>
                </dl>
            </li>
    
        <!-- IF topicrow.S_LAST_ROW -->
                </ul>
            <span class="corners-bottom"><span></span></span></div>
        </div>
        <!-- ENDIF -->
    
    <!-- BEGINELSE -->
        <!-- IF S_IS_POSTABLE -->
        <div class="panel">
            <div class="inner"><span class="corners-top"><span></span></span>
            <strong>{L_NO_TOPICS}</strong>
            <span class="corners-bottom"><span></span></span></div>
        </div>
        <!-- ENDIF -->
    <!-- END topicrow -->
    
    <!-- IF S_SELECT_SORT_DAYS and not S_DISPLAY_ACTIVE -->
        <form method="post" action="{S_FORUM_ACTION}">
            <fieldset class="display-options">
                <!-- IF PREVIOUS_PAGE --><a href="{PREVIOUS_PAGE}" class="left-box {S_CONTENT_FLOW_BEGIN}">{L_PREVIOUS}</a><!-- ENDIF -->
                <!-- IF NEXT_PAGE --><a href="{NEXT_PAGE}" class="right-box {S_CONTENT_FLOW_END}">{L_NEXT}</a><!-- ENDIF -->
                <label>{L_DISPLAY_TOPICS}: {S_SELECT_SORT_DAYS}</label> 
                <label>{L_SORT_BY} {S_SELECT_SORT_KEY}</label> 
                <label>{S_SELECT_SORT_DIR} <input type="submit" name="sort" value="{L_GO}" class="button2" /></label>
            </fieldset>
        </form>
        <hr />
    <!-- ENDIF -->
    
    <!-- IF .topicrow and not S_DISPLAY_ACTIVE -->
        <div class="topic-actions">
            <!-- IF not S_IS_BOT and S_DISPLAY_POST_INFO -->
            <div class="buttons">
                <div class="<!-- IF S_IS_LOCKED -->locked-icon<!-- ELSE -->post-icon<!-- ENDIF -->"><a href="{U_POST_NEW_TOPIC}"><span><!-- IF S_IS_LOCKED -->{L_FORUM_LOCKED}<!-- ELSE -->{L_POST_TOPIC}<!-- ENDIF --></span></a></div>
            </div>
            <!-- ENDIF -->
        
            <!-- IF PAGINATION or TOTAL_POSTS or TOTAL_TOPICS -->
            <div class="pagination">
                <!-- IF TOTAL_TOPICS and not S_IS_BOT and U_MARK_TOPICS --><a href="{U_MARK_TOPICS}">{L_MARK_TOPICS_READ}</a> &bull;  <!-- ENDIF -->
                <!-- IF TOTAL_POSTS and not NEWEST_USER --> {TOTAL_POSTS}<!-- ELSEIF TOTAL_TOPICS and not NEWEST_USER --> {TOTAL_TOPICS}<!-- ENDIF -->
                <!-- IF TOTAL_USERS -->{TOTAL_USERS}<!-- ENDIF -->
                <!-- IF PAGINATION --> &bull;  <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a>
                 &bull;  <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF -->
            </div>
            <!-- ENDIF -->
        </div>
    <!-- ENDIF -->
    
        
    <!-- INCLUDE jumpbox.html -->
    
    <!-- IF S_DISPLAY_ONLINE_LIST -->
        <h3><a href="{U_VIEWONLINE}">{L_WHO_IS_ONLINE}</a></h3>
        <p>{LOGGED_IN_USER_LIST}</p>
    <!-- ENDIF -->
    
    <!-- IF S_DISPLAY_POST_INFO -->
        <h3>{L_FORUM_PERMISSIONS}</h3>
        <p><!-- BEGIN rules -->{rules.RULE}<br /><!-- END rules --></p>
    <!-- ENDIF -->
    
    <!-- INCLUDE overall_footer.html -->
    
  • Open the file "./styles/prosilver/theme/content.css".
  • Find the following code:

    Code: Select all

    dd.posts, dd.topics, dd.views {
    	width: 8%;
    	text-align: center;
    	line-height: 2.2em;
    	font-size: 1.2em;
    }
    
  • Replace it with the following:

    Code: Select all

    dd.posts, dd.topics, dd.views, dd.likes {
    	width: 5%;
    	text-align: center;
    	line-height: 2.2em;
    	font-size: 1.2em;
    }
    
Update 1/11/11: Added Permission Filter to get_liked_list function so that the Thread list does not contain threads from forums user does not have permission to.
Last edited by digioz on Wed Jan 12, 2011 4:31 am, edited 1 time in total.
DigiOz Multimedia
http://www.digioz.com

User avatar
keith10456
Registered User
Posts: 2315
Joined: Thu Feb 24, 2005 6:55 pm
Contact:

Re: [DEV] "Like" Mod

Post by keith10456 » Mon Jan 03, 2011 6:30 pm

Do you have a screenshot of how it look upon completion?

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Mon Jan 03, 2011 8:17 pm

keith10456 wrote:Do you have a screenshot of how it look upon completion?
Here are two screenshot of how the "Liked List" looks as of right now:

Image

Image
DigiOz Multimedia
http://www.digioz.com

User avatar
keith10456
Registered User
Posts: 2315
Joined: Thu Feb 24, 2005 6:55 pm
Contact:

Re: [DEV] "Like" Mod

Post by keith10456 » Mon Jan 03, 2011 8:43 pm

Thanks... Looks good 8-)

User avatar
ASD2010
Registered User
Posts: 134
Joined: Wed Oct 20, 2010 4:49 pm
Location: Guatemala, City
Name: Wil Elias

Re: [DEV] "Like" Mod

Post by ASD2010 » Thu Jan 06, 2011 9:48 pm

Excellent mod, work fine. the list...nice!!!!

thanks digioz :D
the best style: Absolution... :D

help in spanish
sorry my bad english..... :D

Ozo
Registered User
Posts: 330
Joined: Mon Dec 13, 2010 7:57 pm

Re: [DEV] "Like" Mod

Post by Ozo » Fri Jan 07, 2011 1:57 am

Looking nice :)

User avatar
EFiNSTORM
Registered User
Posts: 160
Joined: Fri Dec 26, 2008 4:09 am
Location: localhost

Re: [DEV] "Like" Mod

Post by EFiNSTORM » Fri Jan 07, 2011 5:12 am

great to see that you got the list of ppl who like the tread. If you have some time can you make the modx format for the install thanks.

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Sat Jan 08, 2011 7:46 pm

EFiNSTORM wrote:... If you have some time can you make the modx format for the install thanks.
The reason I haven't made a modx file yet is because I don't want non-programmers to start using this mod in a production environment until the mod is complete. The reason this mod is in the "MODs in Development" forum right now is because I wanted to collaborate with other programmers in the phpbb community when working on the mod. I hope this makes sense.

Having said that, if someone does decide to use the mod in a live forum before it is done do so At your own risk.

Thanks,
Pete
DigiOz Multimedia
http://www.digioz.com

rizfield
Registered User
Posts: 23
Joined: Fri Dec 09, 2005 3:56 pm

Re: [DEV] "Like" Mod

Post by rizfield » Wed Jan 12, 2011 6:23 am

can this like mod like a single post? instead of a whole topic?

User avatar
digioz
Registered User
Posts: 297
Joined: Thu Feb 05, 2004 9:20 pm
Location: Chicago, IL
Name: DigiOz Multimedia
Contact:

Re: [DEV] "Like" Mod

Post by digioz » Wed Jan 12, 2011 7:39 am

rizfield wrote:can this like mod like a single post? instead of a whole topic?
Not in it's current form, no and i don't want to take it down that route. The concept however could be reworked obviously to do so.
DigiOz Multimedia
http://www.digioz.com

rizfield
Registered User
Posts: 23
Joined: Fri Dec 09, 2005 3:56 pm

Re: [DEV] "Like" Mod

Post by rizfield » Wed Jan 12, 2011 7:46 am

thx for clearing up, hope on later version, there will be option to like single post too..

my forum is waiting for your mod.. :)

Locked

Return to “[3.0.x] Abandoned MODs”