RGraph on XAMPP with AJAX

« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by Eric on 15th July 2016

First of all, what a great product!!

In my office we use XAMPP with PHP to show a narrowcasting system, where I am trying to show some of your graphs with AJAX to keep track on progress.

I think I am not working locally, but I cannot make a working sample of gauge-ajax.html. It will load the first value initial and then seems to load the first value in the file getHTML, makes a move to that value and then stops.

I don't see any errors, but the animation stops.

Your help would be more than welcome. Thank you for your reply.

(FYI: all links in the sourcefile are redirected okay and load the appropriate content. Sample url:

(I checked with Fiddler the loadings and the getHTML-file seems to get loaded only once)

I hope you can point me in the right direction.

Kind regards,
Posted by Richard on 15th July 2016
Hi there,

You are working either locally or using a web server on your local network - the IP address ( is not a public address.

Are you getting the initial value by AJAX? If so then maybe your timer is not repeating itself. Are you using setTimeout()? That doesn't repeat itself automatically - it only occurs once. You could do something like this instead:

function update ()
     // This function should get the value (by AJAX in your case
     // and draw the Gauge

     // Update the gauge again in 5 seconds
     setTimeout(update, 5000);

// Initially, draw the gauge straight away
setTimeout(update, 100);

Posted by Enter your name... on 15th July 2016
Hi Richard,

Wow, thank you for your early reply. My excuses, but I'm a newbie with this!

Would it be to much if I may ask you to send me the code of what you want me to do?
I tried what you said, but I think I make the wrong adjustments.

If you could send me just a sample of what you try to tell me, that would help me a lot in understanding to coding.

I know I ask a lot, but you would help me with that, a great deal.

I hope to hear from you again and many thanks in advance.

Kind regards,
Posted by Richard on 15th July 2016
Hi there,

I did - the setTimeout function is in the previous post.

Posted by Richard on 15th July 2016
Hi there,

Also, I think this demo matches your situation very closely:



Add a reply

« Back to message list