I'm building a WordPress site for a reading challenge where users will sign up for an account and visit the site daily to enter the number of pages they've read.
I'm using BuddyPress for the user signup, but would like advice on how to handle the daily page count data entry.
I need to be able to use the page count number they enter to display that data on a graph in their profile of pages per day, and also to display the cumulative data across all users each day in a graph on the home page. Any suggestions on how to code this?
I'm building a WordPress site for a reading challenge where users will sign up for an account and visit the site daily to enter the number of pages they've read.
I'm using BuddyPress for the user signup, but would like advice on how to handle the daily page count data entry.
I need to be able to use the page count number they enter to display that data on a graph in their profile of pages per day, and also to display the cumulative data across all users each day in a graph on the home page. Any suggestions on how to code this?
Here's a rough outline / concept how I would approach the challenge. Others might come up with different solutions, but I think something like this should get the job done.
reading_challenge
, to store the data. Add author
support to the post type so that the posts can be linked with your users. The cpt doesn't need to be public.post_meta
or update existing post meta.transient
instead of doing the query and counting on every home page load.