nblgeoweb VIP
Total posts: 178
02 Sep 2014 09:56

I needed to build a filter URL with a date range but never found a specific example or documentation on how to do it. There was a thread a while back asking about it but there never was a solution. After a bit of experimentation and digging I came up with the correct syntax so I figured I would share it here for others who might have the same question:

/index.php?option=com_cobalt&task=records.filter&section_id=11&item_id=1934&filter_name[0]=filter_ke45f9d3bb288049d6cc4a470829a9e43&filter_val[0][range]=2014-09-01,2014-09-30

Replace section_id, item_id, and filter_name values with those appropriate to the id's and filter key used on your site. The filter_val[0][range] paramater is a comma separated list of dates - starting and ending dates for the range.

It would be great if an example for date range was added to the cobalt docs at http://docs.mintjoomla.com/en/cobalt/prefiltered-links/ somewhere around where it discusses using array keys probably.

Last Modified: 15 Oct 2014


pepperstreet VIP
Total posts: 3,837
02 Sep 2014 10:16

+1

nblgeoweb example for date range was added to the cobalt docs

Agree!


Sergey
Total posts: 13,748
15 Oct 2014 02:27

I'll add this example to docs later.

Powered by Cobalt