The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

like dislike with count [PunBB]

View previous topic View next topic Go down

like dislike with count [PunBB]

Post by zenzo on March 29th 2013, 10:20 am

how can i make like dislike diagonal and with count like on this image



i have code here vote with count

javascript
Code:
(function($){
$(document).ready(function(){
$('.vote-bar').each( function() {
    var s = $(this).attr('title');
    var g = s.split("(");
    var n = g[1];
    var m = n.replace(")", "");
    $(this).children(".vote-bar-plus").html(m);
});
$('.vote a[href$="eval=plus"]').append(function(){
$(this).html('<img src="http://icons.iconarchive.com/icons/icojam/blue-bits/32/thumbs-up-icon.png"/>');
});
$('.vote a[href$="eval=minus"]').remove();
});
})(jQuery);

CSS
Code:
.vote-button img{opacity:0.3;}
.vote-button img:hover{opacity:1;}
.vote-bar-plus{color:#fff !important;padding-top: 4px;}
.vote .vote-bar{font-size:12px !important;border:1px solid #fff !important;width:100% !important;height: 22px !important;text-align: center;background: rgb(92, 91, 91);box-shadow: inset -3px -8px 19px rgba(0, 0, 0, 0.7);}
.vote{width: 6% !important;}
.vote .vote-bar-plus{background-color:transparent !important;}

zenzo
Forumember

Posts : 464
Reputation : 13
Language : english,tagalog
Location : philippines

Back to top Go down

Re: like dislike with count [PunBB]

Post by SLGray on March 29th 2013, 10:46 am

That JavaScript will remove the minus (dislike count).
Code:
$('.vote a[href$="eval=minus"]').remove();


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35667
Reputation : 2375
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Re: like dislike with count [PunBB]

Post by zenzo on March 29th 2013, 1:13 pm

@SLGray wrote:That JavaScript will remove the minus (dislike count).
Code:
$('.vote a[href$="eval=minus"]').remove();

i mean can you help me modify that code so it will look like this

zenzo
Forumember

Posts : 464
Reputation : 13
Language : english,tagalog
Location : philippines

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum