0

I am generating line graphs of meteorological data using Dygraphs, and would like to implement a date range picker so that users can input a specific date or range of dates and see the data represented in said graph. I have scoured various websites and JSFiddle examples for other charting libraries which have not worked correctly (or in some cases at all).

Here is a Fiddle of my current graph. I have found the following code for creating the datepicker. Now I just need to implement it.

<input type="text" name="daterange" value="01/01/2015 - 01/31/2015" />
  <script type="text/javascript">
     $(function() {
     $('input[name="daterange"]').daterangepicker(); 
     });

Can someone point me in the right direction? Many thanks.

  • do you need to enable a date rage in datepicker? – Sinto Jan 28 '16 at 06:43
  • http://stackoverflow.com/a/1962849/4229270 – Sinto Jan 28 '16 at 06:51
  • @sinto, I'm not entirely sure I understand what you're asking. The datepicker itself seems to work, because when I render it, it pops up with the calendar and the range of dates. However, I need to take that range of dates and make the graph show the corresponding data. Here's an example with the datepicker included, just not working to give me the output I desire: http://jsfiddle.net/andrewtlong/r7oenjv5 – Andrew Long Jan 28 '16 at 08:58

0 Answers0