Wedge
Public area => The Pub => Plugins => Topic started by: CerealGuy on December 27th, 2014, 06:43 PM
-
This Plugin basically shows in profile summary how many likes this user gave/receieved. You can also view those posts.
https://github.com/C3realGuy/CountLikes
-
Not something I would use but it gets a thumbs up from me for the achievement. Thumbs up to any plugin authors because I can't do it!
Well done CG!
-
Fixed a weird error with an unrecognized index on fetch_row... I have no idea why it didn't work, possibly a PHP version specific issue.
Here's the file... Also, fixed some indenting, and stuff.
-
Feel free to do a pull request, otherwise i will have a look at it this afternoon.
Thank you for providing your changes :).
If I remember it correctly, the view of the liked posts needs some improvement. I had to apply a complete template, perhaps this could be solved better?! Because in general its the same like the view posts stuff, only different query and other texts. A more general function for that would be helpful maybe. I dont like duplex code :D.
EDIT: Updated git repo
-
On line 90, $context['is_topics'] is undefined... It's copy-pasted from Profile-View.php, where it's defined earlier...
I just removed that code block, working fine now.
-
Didn't get that error yet :hmm:. But thats a block of code where I really don't know what it does.
-
Doesn't matter, you're not offering to view liked topics, only viewed posts, so off it goes.. ;)
-
Okay, I'm just gonna upload this fixed version of the main file. It gave me an error if attempting to view likes that didn't belong to a post. ;)
I used the opportunity to clean it up: fix typos, spacing, and a few database issues.
-
Nice, thank you!
One plugin less to refactor. Did it for hide (actually i completely rewrote it) and recently started it for the invite plugin (should rewrite this one too, but not really worth the time). Doesn't make too much fun, it's just ugly code. I will apply your changes to repo in the next days.
-
Well, I guess I'm lucky, since I couldn't remember where your repo was (I still don't :P), I didn't update it, so I could have redone the same thing you did... As I said, I'm lucky, because I hate wasting time. :P
Hmm, I noticed that Lestrades.com doesn't seem to enable my plugins when I try to turn them on... It only accepts one, I don't know why. So weird.
-
Well, I guess I'm lucky, since I couldn't remember where your repo was (I still don't :P), I didn't update it, so I could have redone the same thing you did... As I said, I'm lucky, because I hate wasting time. :P
If it's not in C3realGuys repos, there maybe is no repo for it. But it should be in the wedge/plugins repo.Hmm, I noticed that Lestrades.com doesn't seem to enable my plugins when I try to turn them on... It only accepts one, I don't know why. So weird.
Wtf. I (maybe, at least it sounds very similiar) have the same exact problem on one install (sadly the productional). What works for me is to enable them in acp and then add it manually to Settings.php enabled plugins. I have no fuckin clue why this happens, but as soon as i get redirected from the enableplugin action to the plugin overview, it changes back to previous enabled plugins. No idea why this happens as it only happens on one install.
Didn't open a bug report yet because i believed it's something with my setup (some weird third party caching or something similiar).
-
Updated the github repository.
https://github.com/C3realGuy/CountLikes
-
On line 90, $context['is_topics'] is undefined... It's copy-pasted from Profile-View.php, where it's defined earlier...
I just removed that code block, working fine now.
I just resurrected my forum by commenting lines 90 & 91 :^^;:
PHP Fatal error: Class 'Likes_Notifier' not found in /opt/sites/www.potesnroll.com/www/gz/app/Notifications.php on line 90
# self::$notifiers['likes'] = new Likes_Notifier();
# self::$notifiers['likes_thought'] = new Likes_Thought_Notifier();
(90 + 91)
Using an up to date Debian with Apache 2.4 and PHP 5.6
-
@Kian
do you get the error because of the CountLikes Plugin?
-
@Kian
do you get the error because of the CountLikes Plugin?
Actually, no, I dont have it, wrong topic :oops: