Thread: Show Thread Enhancements - eTiKeT? 2015 Style Postbit - Postbit_legacy
View Single Post
  #2  
Old 12-02-2015, 08:18 AM
eTiKeT?'s Avatar
eTiKeT? eTiKeT? is offline
 
Join Date: Aug 2008
Location: T?rkiye
Posts: 257
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks if you are using the system.
==================================
Step 1.
Open post_thanks_button template of your default theme, replace all the codes with the ones below :
PHP Code:
 <a href="post_thanks.php?{vb:raw session.sessionurl}do=post_thanks_add&amp;p={vb:raw post.postid}&amp;securitytoken={vb:raw bbuserinfo.securitytoken}" id="post_thanks_button_{vb:raw post.postid}"<vb:if condition="$vboptions[disable_ajax] != 2"onclick="return post_thanks_give({vb:raw post.postid}, <vb:if condition="$vboptions[post_groans_integrate]">true<vb:else />false</vb:if>);"</vb:if> <vb:if condition="$display_thanks_image == 'none'">style="display:none"</vb:if> rel="nofollow" class="fa-ikon fa-ikon-sinir fa-thumbs-o-up post_thanks_button ">{vb:rawphrase post_thanks_thanks}</a>

<
span class="seperator" id="post_thanks_separator_{vb:raw post.postid}" <vb:if condition="$display_thanks_image == 'none'">style="display:none"</vb:if>>&nbsp;</span
Step 2.
Open post_thanks_postbit template of your default theme, replace all the codes with the ones below :
PHP Code:
 <div class="postbody"<vb:if condition="$vboptions['legacypostbit']"style="margin-{vb:stylevar left}: 0"</vb:if>>
    <
div class="postrow">
    <
vb:if condition="$bbuserinfo['usergroupid'] == 5 || $post['show_thanks_remove_option']">
    <
div class="smallfont" style="float:{vb:stylevar right}">
        <
vb:if condition="$bbuserinfo['usergroupid'] == 5">
            <
a href="post_thanks.php?do=post_thanks_remove_all&amp;p={vb:raw post.postid}"<vb:if condition="$vboptions['disable_ajax'] != 2"onclick="return post_thanks_remove_all({vb:raw post.postid}, <vb:if condition="$vboptions['post_groans_integrate']">true<vb:else />false</vb:if>);"</vb:if> rel="nofollow">{vb:rawphrase post_thanks_remove}</a>
        </
vb:if>
        <
vb:if condition="$bbuserinfo['usergroupid'] == 5 && $post['show_thanks_remove_option']">
            |
        </
vb:if>
        <
vb:if condition="$post['show_thanks_remove_option']">
            <
a href="post_thanks.php?do=post_thanks_remove_user&amp;p={vb:raw post.postid}"<vb:if condition="$vboptions['disable_ajax'] != 2"onclick="return post_thanks_remove_user({vb:raw post.postid}, <vb:if condition="$vboptions['post_groans_integrate']">true<vb:else />false</vb:if>);"</vb:if> rel="nofollow">{vb:rawphrase post_thanks_remove_user}</a>
        </
vb:if>
    </
div>
    </
vb:if>
    <
h2 class="<vb:if condition="!$vboptions['legacypostbit']">post</vb:if>title">
        <
vb:if condition="$post['post_thanks_amount'] == 1">
            <
class="fa-ikon fa-ikon-sinir fa-thumbs-o-up vw-bigikon "></i> {vb:rawphrase post_thanks_user_says, {vb:raw post.username}}
        <
vb:else />
            <
class="fa-ikon fa-ikon-sinir fa-thumbs-o-up vw-bigikon "></i>{vb:rawphrase post_thanks_users_say, {vb:raw post.post_thanks_amount_formatted}, {vb:raw post.username}}
        </
vb:if>
    </
h2>
<!--
COLLAPSE-->
    <
vb:if condition="$vboptions['collapse_on']==0">

<
div class="content">
        <
div class="post_thanks_bit_{vb:raw post.postid}">
            <
blockquote class="postcontent restore">
                {
vb:raw post.post_thanks_bit}
            </
blockquote>
        </
div>
    </
div>
    </
div>
</
div>
<
hr />

</
vb:if>

<
vb:if condition="$vboptions['collapse_on']==1">
<
style type="text/css">
.
msg_head {
    
padding5px 10px;
    
cursorpointer;
    
positionrelative;
    
margin:1px;
}
</
style>
<
script type="text/javascript" src="{vb:raw vboptions.bburl}/clientscript/jquery/jquery.js"></script>
<
script type="text/javascript">
$(
document).ready(function()
{
  
//hide the all of the element with class msg_body
  
$(".post_thanks_bit_{vb:raw post.postid}").hide();
  
//toggle the componenet with class msg_body
  
$(".msg_head").click(function()
  {
    $(
this).next(".post_thanks_bit_{vb:raw post.postid}").slideToggle(600);
  });
});
</
script>
    <
div class="content">
<
class="msg_head"><img src="{vb:raw vboptions.bburl}/images/misc/collapse.jpg"</p>
        <
div class="post_thanks_bit_{vb:raw post.postid}">
            <
blockquote class="postcontent restore">
                {
vb:raw post.post_thanks_bit}
            </
blockquote>
        </
div>
    </
div>
    </
div>
</
div>
<
hr /></vb:if>
<!--
END COLLAPSE--> 
Step 3.
Open post_thanks_postbit_info template of your default theme, replace all the codes with the ones below :

PHP Code:
 <vb:if condition="$post['userid']">
    <!-- 
Thanks -->
<
vb:if condition="$post['post_thanks_thanked_times'] == 1">
<
tr><td class="legacystats"> <dt>Thanked:</dt><dd1</dd> </td></tr>
<
vb:else />
<
tr><td class="legacystats"><dt>Thanked</dt><dd> {vb:raw post.post_thanks_thanked_times}</dd></td></tr>
</
vb:if>
<!-- /
Thanks -->
</
vb:if> 
Reply With Quote
2 благодарности(ей) от:
In Omnibus, socialteenz
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02678 seconds
  • Memory Usage 1,918KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_php
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (2)post_thanks_box_bit
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_attachment
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete