Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am working on theme where I am adding vote functionality to comments and posts. What should I use, meta tables or create a new table?

share|improve this question
1  
That depends on your anti-vote fraud mechanism. –  toscho May 11 '13 at 11:38
    
Thanks, that helped me a lot. Using a table can prevent fraud voting by filtering IP and users. –  Noor Ahmad Feroozi May 11 '13 at 12:44
add comment

1 Answer

You can use both:

  1. Comment meta for the plain vote count, because that is easy to fetch with a standard query.
  2. A custom table storing additional data to prevent vote fraud and other issues. These tables might be used for rare events (voting) only, but they are not used to list comments in the back-end or in views where voting is not possible anyway.

So plan performance bottle-necks first, profile, then decide what setup works best for you.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.