简体   繁体   中英

how to make an activity log for chart

I'm trying to make a user activity for my website.

it is not too complicated...

I need to make a chart from user activity table.

it is my database:

+-------+-------+
| date  | count |
+-------+-------+

every activity that happens the count field goes up.

then I can find out user activity in every moments.

the result:

count|                       o   o  o
     |                    o
     |      o  o  o     o
     |  o           o  
     |o
     |_____________________________________date

the question is, am I doing right? or there is better way for this type of charts?

because I think this way is not optimal.

you can use mscharts to display charts on user screen. For displaying charts you need to use jquery or javascript. Record every activity in your database. Than when you want to display chart query the database and pass the result as json so that jquery/javascript recieve the data and display the chart.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM