Board Logo

 Username:    Password:    Stay logged in: Welcome Guest. Please Login or Register.  Nov 21st, 2017, 05:58am

Coding Forum
Important News
Remember to add where the code goes in the headers/footers.

Also, please check the list of codes on the Hacks board, especially if you have an error. The code may already have been corrected.
Thanks.
Welcome to the Conforums Hacks Board!

Please follow these simple rules.

1. No spamming.
2. Do not advertise your board in here!
3. Keep on topic, or the thread will be locked.
4. No flame wars.
5. No bringing up old topics.

Please note: For codes other than those submitted in the Hacks Forum, please ask for permission to use from the creator. Be aware that coding queries in the Coding Forum become public domain. If you still seek coding help but find it inconvenient to display it publicly then please PM one of the moderators. We encourage all queries to be submitted here in hopes to help other members who might have the same question. Thank you.

Helpful sites
Google
Dynamic Drive

The Staff
Roger
Dave
Gizzy



« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Like/Dislike System  (Read 1732 times)
Nemle22
Member


member is offline

Avatar




PM


Posts: 97
exclamation Like/Dislike System
« Thread started on: Jun 3rd, 2013, 08:52am »

A like/dislike system...sort of like how Facebook has. There's a code for it on the v4 Proboards so I was curious if there was one for Conforums as well?
User IP Logged

Dalton
Ex-Shiny Gold Star Club Member
Conforums Administrator


member is offline

Avatar



AIM
Homepage PM

Gender: Male
Posts: 1771
exclamation Re: Like/Dislike System
« Reply #1 on: Jun 3rd, 2013, 4:06pm »

V4 Proboards had a built in "Karma" system on the server side, the like/dislike script in question simply modified the terms used.

The problem that leaves us here is that since the software has no built in system to tally likes or dislikes, or as it was known on Proboards Karma and Hate. Is that there is no RELIABLE method to tally likes without the server side.


having javascript that created a cookie would require a user to like/dislike a post before he would see the likes and dislikes for example and after someone had liked it they would be unable to see any likes afterwards.

The only thing I could think that would work would be perhaps creating a script that creates a cookie FOR you to see if you like or dislike a post. So for example


"User x has posted this really long annoying thread" Like/dislike

you click dislike and it would attach a cookie to your browser to toggle "You have disliked this thread' No one else would see that you had disliked it due to the cookie being local, and if you cleared your temporary internet data you would lose your likes and dislikes.

None of this seems terribly reliable so I guess the short method is, no, due to the lack of built in Karma system I am definitely going to be unable to get you something you would like.
User IP Logged

User Image
kady
Member


member is offline

Avatar




Homepage PM

Gender: Female
Posts: 63
exclamation Re: Like/Dislike System
« Reply #2 on: Jul 28th, 2013, 7:31pm »

Aw, darn. Here I was, about to ask for a "like" button as well. *Sighs* Oh well...

It can't even be a simpler system where, even though someone can probably abuse the method, it wouldn't have a cookie, and just keep a tally of how many times the "like/dislike" button gets pressed in total? I understand the many faults in the fact that the original poster can like their own post, and can also press "like" an infinite amount of times, but still it is a much simpler method that I don't think requires a cookie. Is this simpler method possible?
« Last Edit: Jul 28th, 2013, 7:31pm by kady » User IP Logged

Cmaza
Full Member


member is offline

Avatar




PM

Gender: Male
Posts: 851
exclamation Re: Like/Dislike System
« Reply #3 on: Sep 11th, 2013, 01:33am »

Might be a bit beyond the scope of what is being asked for or discussed here.. But, I imagine it'd be fairly easy to cobble together a system to achieve what is desired here [Like/Dislike tally system] by using AJAX to connect to an external service using an API or hashkey system (probably coded using php or perl).

Biggest problem with this would be, how do you prevent people from hammering the like button, or finding ways to cheat the system? One way around this - If Conforums had a way of generating a unique pseudo-random hashkey for each user (I'm not thinking anything to do with passwords, more just something simple like md5[salt+subdomain+username]) which could be called as a variable by its templating system when logged in, that pseudo-random hashkey could be used as a fairly reliable identifier for who's liking/hating what on what board (could just request a page on a remote service using AJAX which includes the page URL and the haskey, which is then called back using AJAX to display how many likes/hates that thread/board/etcetera has).

Still a tiny bit of work for Conforums to do for this to work, but less work than setting up an entire system themselves, seeing as this idea wouldn't require Conforums to find a reliable way of storing the data (would be handled by the external service).

No hair off my back seeing as I self-host now anyhow, but, saw this thread and thought I'd throw the idea out there. smiley
« Last Edit: Sep 11th, 2013, 01:35am by Cmaza » User IP Logged

Dalton
Ex-Shiny Gold Star Club Member
Conforums Administrator


member is offline

Avatar



AIM
Homepage PM

Gender: Male
Posts: 1771
exclamation Re: Like/Dislike System
« Reply #4 on: Sep 22nd, 2013, 02:24am »

Oh I know how I would do it on the server side, Im just wanting to push big upgrades like this into the development cycle of the version rather than based off a request.

Fully functional serverside > halfassed javascript

I also need my paid job and real life to stop hassling so much so I can spend more time developing here.
« Last Edit: Sep 22nd, 2013, 02:24am by Dalton » User IP Logged

User Image
Cmaza
Full Member


member is offline

Avatar




PM

Gender: Male
Posts: 851
exclamation Re: Like/Dislike System
« Reply #5 on: Sep 26th, 2013, 07:28am »

Fair enough, and no worries; Of course, I agree that something server-side would be a hell of a lot better than anything done with JavaScript, but, it's always fun to discuss these things nonetheless. smiley
User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

Back To Top
Donate $6.99 for 50,000 Ad-Free Pageviews!

| |

This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls