Answer the question
In order to leave comments, you need to log in
Where can I find a clear example of plotting graphs in php or js?
Friends, I can’t find anywhere a simple easy example of creating a line graph "let's say site visits"
For those who can help, send some information on how to generate a simple site visit graph
in php GD or javascript SVG
The question has a big bias on the principle of creating a graph, what rules are needed observe to generate it?
Please do not offer ready-made solutions like phpChartFrameworkBundle2017_packRepackPro which, let's say, weighs 90 megabytes. Here's a simple example to get the point across.
Answer the question
In order to leave comments, you need to log in
for example, we receive data from the server in the form
[{day: 1, visitors: 10},{day: 2, visitors: 20},{day: 3, visitors: 15}]
and in js we draw an svg line with coordinates
x - day
y - visits
what other rules then? To work with svg in js, I personally use svgjs.com
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question