Closed (fixed)
Project:
Date
Version:
7.x-2.1
Component:
Date API
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Feb 2012 at 11:17 UTC
Updated:
16 Mar 2012 at 23:30 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
JoshOrndorff commentedI'm getting the same problem using an exposed date filter in views 7.x-3.1
Is this the proper fix?
Comment #2
JoshOrndorff commentedAnd it is still happening in the -dev as of 02 February 2012.
Comment #3
jlpicard2 commentedAfter updating to Date RC2, I was getting the error on Views pages with a default date of "now".
• Warning: array_filter() expects parameter 1 to be array, null given in date_select_input_date() (line 699 of /var/www/html/sites/all/modules/date/date_api/date_api_elements.inc).
• Warning: array_values() expects parameter 1 to be array, null given in date_select_input_date() (line 699 of /var/www/html/sites/all/modules/date/date_api/date_api_elements.inc).
The fix above corrects these warnings.
Comment #4
phoang commentedSubscribe. I'm having same issue when updating to RC2.
Comment #5
extrarumeno commentedsubscribe
same error To RC2
Comment #6
sgabe commentedI can confirm the error.
Comment #7
sgabe commentedSee the attached patch.
Comment #8
kkasischke commentedPatch in #7 worked for me. Thanks!
Comment #9
gaele commentedYup.
Comment #10
bschilt commentedPatch in #7 worked for me too.
Comment #11
goliat2 commenteddoesn't work for me ! please help !
#7 creates "internal error"
Comment #12
SilviuChingaru commentedPatch in #7 worked fine for me too. Thank you!
Comment #13
gaele commentedgoliat2, if you see an "internal error" the error_log of the webserver should provide a clue of what went wrong.
Please share that information with us.
Comment #14
karens commentedI can't tell if this is the right patch or if something else needs to be done unless someone can tell me how to reproduce the error. I don't have any such error.
Comment #15
goliat2 commentedThanks for the tip #13 and it seems to be a PHP Parse error.
Could someone attach the entire file "date_api_elements.inc" so that i can download it and test it ?
Thanks
Comment #16
Blooniverse commented@goliat2#15: Just download the latest dev version (2012-02-09) from http://ftp.drupal.org/files/projects/date-7.x-2.x-dev.zip respectively http://drupal.org/project/date ! The current commits/patches should be in there. Or ... did you want to get the fully patched 'date_api_elements.inc' due to not knowing how patching works? Then please consult http://drupal.org/node/707484 or http://drupal.org/node/620014 or http://drupal.org/node/60108, depending on your aims.
Comment #17
Blooniverse commented@goliat2#15: The user/browser script 'Dreditor' (http://drupal.org/project/dreditor) can be of great help when working with patches, by the way. It serves as a visual patch reviewer directly inside the browser, which makes life easier.
Comment #18
Blooniverse commentedThe patch 'date-1425774-7.patch' from @sgabe#7 does get rid of the error message in my case. But it does not solve the pager issue explained in #1433518: Filter & pager influence view result -- but not mutually each other ! The query string arguments / array elements still only consist of keys, but there are no values -- in the mentioned context of a View in combination with an exposed filter (a date field, select form element). This does not happen when I make use of the popup form element!!!
@goliat2#15: If you want to make use of the patched file 'date_api_elements.inc' (7.x-2.0-rc2), please download the zipped attachment from here.
Comment #19
goliat2 commentedThank you very much for your help.
I'm not sure i've understood everything about patches but i download your file and uploaded it on my website.
You're right it works only with pop up and text but not on select.
But i would like in my case to make it work on select.
Hope it will be fixed soon !
But thanks again
Comment #20
Blooniverse commented@goliat2#19: You're welcome! You will see, in a few days [or weeks] you will be able to manage the drupal.org issue workflow easier. Besides, I would like to improve my #16-hint: The complete Git instructions are usually found on http://drupal.org/project/foo/git-instructions, in this case http://drupal.org/project/date/git-instructions ! Here it is as well where a section about the patching procedure can be found.
Comment #21
SilviuChingaru commentedThere is still one problem (maybe feature request for some but I see it more a bug):
If only start date is set and end date is not set, data should be filtered from start date to now().
If only end date is set and start date is not set, start date timestamp should be set to 0.
I think this should be normal behavior.
Comment #22
Anonymous (not verified) commentedHad the same problem with a date select fliter on a view with granularity year (single date select). Patch #7 solved this, thanks. I think #21 is a point for discussion elsewere.
Comment #23
karens commentedNote that nothing will happen with this patch unless someone responds to #14.
Comment #24
gaele commentedKarenS, this is my view that produces the warning.
Comment #25
sgabe commented@KarenS: As mentioned in #1, using an exposed filter produced the error.
I have a view with events and an exposed date filter set to use only the year as a select list, so the user can list events for a specific year. The error message occurs when I load the page the first time and the filter has it's default value and no user input. If I choose another year then the error goes away.
The patch eliminates this error.
Comment #26
karens commentedOK, finally got where I could see this. Thanks!
http://drupalcode.org/project/date.git/commit/b8da004
Comment #27
Blooniverse commentedw00t — and very likely already in '7.x-2.x-dev'!?!
Comment #28
rafinskipg commentedPatch in #7 worked for me
Comment #29
JoshOrndorff commentedI just upgraded to 7.x-2.1, and the original message is fixed, but is replaced with:
Comment #30
karens commented#29 is a totally different issue. If you have a different message you have a different issue.
Comment #31
Blooniverse commented... #29 sounds familiar, sounds like one of many lacking
isset()s!Comment #32
rylowry@gmail.com commented#29 - I'm also having this problem.
I have an exposed filter for choosing nodes within a date range. I'm on version 7.x-2.2. Is this a new issue altogether?
Comment #33
rylowry@gmail.com commentedHere is a workaround I used for the problem described in #29. I don't know what caused the problem in the first place, but if you really want to get rid of the warning, this worked for me.