Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Vote It
I am totally new to PHP, but have been actively hosting or creating blogs and HTML based websites for the past 2 to 3 years.
Besides having a few requests (which I'll start a discussion separately for each), how would one create a "vote-it-to-the-front-page" extension or add-on similiar to Digg.com? For those unfamiliar with Digg, users are contiually submitting news and information and other users can vote "yay" or "nay" for the posting. Those postings that reach the minumum threshold limit and a beat-out all the other posts make it to the frontpage.
I am looking for something like this, where the admin can control the number of top-voted discussions to appear on the mainpage that loads when you go to the forum. As well, the admin would have to be able to set the threshold (i.e. when you have 15 votes you get thrown in the pool to make it on the frontpage).
I think this method of displaying top discussions would be powerful and make the site more interactive.
Does anyone out think they can help a beginner or even program an extension to meet these requirements?
Thank you in advance for any help.
Besides having a few requests (which I'll start a discussion separately for each), how would one create a "vote-it-to-the-front-page" extension or add-on similiar to Digg.com? For those unfamiliar with Digg, users are contiually submitting news and information and other users can vote "yay" or "nay" for the posting. Those postings that reach the minumum threshold limit and a beat-out all the other posts make it to the frontpage.
I am looking for something like this, where the admin can control the number of top-voted discussions to appear on the mainpage that loads when you go to the forum. As well, the admin would have to be able to set the threshold (i.e. when you have 15 votes you get thrown in the pool to make it on the frontpage).
I think this method of displaying top discussions would be powerful and make the site more interactive.
Does anyone out think they can help a beginner or even program an extension to meet these requirements?
Thank you in advance for any help.
0
This discussion has been closed.
Comments
In order to calculate a discussion's popularity / votes, I'd add a new column to the discussion table that keeps a running tally of the votes. If someone gives a +1, it adds one, If they change their vote to a -1, it removes a vote. It's default value is 0. You can then run a query on the discussion table sorted by the votes descending where the vote must be greater than zero.
I'd also have an expiry date in the logic somewhere - so that discussions that got a lot of votes but haven't been active for a certain number of days disappear from the list.
Thank you for the detailed explanation you provided. I understand what you are getting at, I just wish I was more knowledgeable when it comes to PHP, databases and Vanilla, cause if I were, I'd tackle the project myself.
like the rating thing though, especially in combination with some filter to hide unrated or negatively rated things.