1

I have a simple Drupal form. I am using hook_theme() to draw a chart right under my form. I am using Google chart API. When the page loads first time, my chart appears with no problems. But when I submit my form I use ajax_command_replace() to replace my chart with another one (without page reload). The goal is to make it possible to send variables from my form right to my theme function and draw another chart according to them. The problem is when I push the submit button the old chart disappears (which is good) and the new chart doesn't appear (which is bad). What am I doing wrong?

  • please include your code you are using right now. – WaQaR Ali Aug 12 '15 at 13:18
1

The issue is already created on drupal.org for this and you can try the code from the below mentioned url: Ajax load of chart

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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