MyBB Community Forums

Full Version: MyLikes v1.0.1
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9
I found the problem , great plugin Smile
(2014-11-19, 10:22 PM)Jones H Wrote: [ -> ]It's a known issue which will be fixed in the next version.

Thanks man, really you are willing to help.  Angel
Hi, to allow to users look own likes:


In mylikes.php

if($mybb->user['uid'] == $post['uid'])
    return;

Change in

if($mybb->user['uid'] == $post['uid'])
 $post['button_like'] = eval($templates->render("postbit_mylikes_button"));



In template postbit_mylikes_button you'll need edit text "I like / I don't like" with template conditionals of mybbhacks.zingaburga.com.

Add <if $mybb->user['uid']!=$post['uid'] then> .. </if> around {$mylikes}.

Mine is this, your could be a few different, so add only <if> thing:

<if $mybb->user['uid']!=$post['uid'] then>
<a href="javascript:addLike({$post['pid']}, {$post['uid']}, {$likes}, '{$success}', '{$delete}', '{$lang->mylikes_likes}', '{$lang->mylikes_like}', '{$lang->mylikes_unlike}');"><span id="like_{$post['pid']}" class="mylikes_like {$liked}">{$mylikes}</span></a>
</if>
I won't require template conditionals so I'll simply split the template into two. But atm I'm working on another project so it'll take some time till I'll fix it.
Jones, I sent you a pull request on github that fixes it; if its too crappy to accept I will understand Big Grin

[attachment=33336]
How to install this plugin , somebody can help me !
As every other plugin: simply upload all files the same way they're packed, then go to your acp -> configuration -> plugins and click on Install.
Jones, thanks for the plugin.  I tried to install your update so that the postbit buttons are separated, but I saw the following message after uploading the new files:

Quote:You've uploaded a new version of this plugin which requires some changes! Please run an upgrade.


When I tried to run the upgrade, I got the following message:

Class 'JB_mylikes_Version_Manager' not found in /home4/xxx/public_html/forum/inc/plugins/jones/core/Core.php on line 226

I have installed your Core package located here:

https://github.com/JN-Jones/JonesCore

I'm not the most technically savvy person, so I wonder if you can advise me how to fix this error and update MyLikes.  Thank you for any help you can render.

EDIT: I uninstalled and reinstalled the plugin, which eliminated the upgrade message. Unfortunately, I still can't see likes on my own posts, but I guess that will come in the next version.
It's still a development version, the update hasn't been written. First I need to fix the firefox error.

However, you should be able to view your own likes already, the buttons are located in different templates and the permissions have been split too. Are you sure that the reputation permissions are set correctly, especially the usergroup ones?
(2015-01-21, 09:55 AM)Jones H Wrote: [ -> ]It's still a development version, the update hasn't been written. First I need to fix the firefox error.

However, you should be able to view your own likes already, the buttons are located in different templates and the permissions have been split too. Are you sure that the reputation permissions are set correctly, especially the usergroup ones?

I'm not sure, what setting should I check? As far as I can tell, essentially all reputation-related settings are set to on (especially for my Administrator account), so I'm not sure which one would block just the ability to see likes on one's own posts. Any guidance would be much appreciated.

I thought perhaps it was related to the theme (Vienna), but I can't see likes on my own posts in the default theme, either.
Pages: 1 2 3 4 5 6 7 8 9