No date picker
-
My event continually gets rejected with this message: “Dates must have correct formatting. Please use the date picker provided.”
There is no date picker, only edit boxes. I’ve put in several different formats. No idea what the correct one is. Boo!
-
Well, here’s why: I run a test WordPress site running on my local machine. The way that EM is constructing the path to load javascript doesn’t work for local servers. For example:
Failed to load resource: the server responded with a status of 404 (Not Found) https://wordpress.dev/wp-content/plugins/home/XXX/Projects/WordPress/Serv…ent/plugins/events-manager/includes/css/events_manager_admin.css?ver=3.5.1
Suggestion: At least provide the proper format in text in that widget box. It would be a simple matter to type this in myself and just bypass the broken JS loading.
I just tried on a remote server and at least the edit box behaves differently (I can’t type in colons or alphabetic characters) but it still fails to accept any format that I type in. Plus, I see no “date picker” still. I’ve deactivated every plugin as well.
just to narrow down the problem have you tried to temporarily:
– deactivating all other plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).
– switching to the default theme to rule out any theme-specific problemsI deactivated all plugins – no luck. I changed my theme – I got the date picker.
I then saw that the format was DD/MM/YYYY. So, I took the date that I successfully entered into my online site and pasted it into my local site – same error message.
This is really brittle. It should work if you simply type in a date according to the proper format. It’s just an edit box.
I need it to work locally so I can debug other plugins. Even with the plugin’s incorrect path construction on local servers, this should still work (the form is indeed being submitted, therefore if I type the date properly, it should work). Am I just out of luck?
UPDATE – I just noticed that despite the error message, a draft is saved with the *current* date and 12:00am. However, if I click on the draft, the event appears in the editor with blank dates.
This should be some good info for the dev to work with:
1) Incorrect path construction when run locally
2) Typing by hand doesn’t work, even when using the format given by the date picker
3) Draft is with current date and 12:00AM even when error message appears.UPDATE – I just noticed that despite the error message, a draft is saved with the *current* date and 12:00am. However, if I click on the draft, the event appears in the editor with blank dates.
This should be some good info for the dev to work with:
1) Incorrect path construction when run locally.
2) Typing date by hand doesn’t work, even when using the format given by the date picker.
3) Draft is saved with current date and 12:00AM even when error message appears. It’s not possible to publish this event.sounds like you have a javascript problem somewhere, are you doing this on the front-end or the back-end of your site?
this is a common reason why datepickers stop working, either that or your theme is adding a jQuery or jQuery UI library from within the theme folder.
Thanks for the reply, Marcus. I’m not sure what you mean by “are you doing this on the front-end or the back-end of your site?” I’m not sure what “this” is or front-end vs. back-end in this case. I’m just trying the basic scenario: Adding a new event from the “Add Event” screen, but am being shut down because of date picker problems.
To summarize:
- Local site: Events Manager script loading doesn’t work locally because of path issues (described above). If I could just type in the date, this would be solved.
- Site on the internet: Yes, this was failing because of a conflict with my theme (“Pendulum” by Rascal Labs). I tested by changing the theme to WP 2011 and it worked fine.
For my purposes, I don’t need it to work on the internet. I’m working on a plugin that will integrate with Events Manager, so I do all my developing and testing locally. But, not being able to type in the date and have the date be accepted is crippling. I type in the exact format that the date picker provides and it’s still rejected.
This is all I’m asking: How can I simpy use a keyboard to type in the date of the event?
maybe this can help you out – https://msyk.es/blog/prevent-jquery-wordpress-theme/
Adding a new event from the “Add Event” screen,
I’m asking if you’re trying the above on the admin area, or on your site itself using our front-end features. I guess though given your last reply it doesn’t matter anymore as you know why datpickers don’t work.
How can I simpy use a keyboard to type in the date of the event?
ATM, you have to use the datepicker, hoping to be able to change that in the near future.
script loading doesn’t work locally because of path issues
I develop and test on local sites all the time without DP or path issues. Could it be your site_url and home_url is incorrect? See this – https://codex.www.ads-software.com/Changing_The_Site_URL
Thanks. I’ll check that link out. I do use my own domain name locally (wordpress.dev), maybe that’s the issue.
Yes, would be nice to be able to use the edit box since the date picker appears to be so brittle.
I was using the admin area to add an event.
Thanks for the update.
for sure you can get it to work locally (I use vhosts like wp.lan), good chance it is what I mentioned.
agreed on the datepicker, hoping to make that degrade more gracefully in the near future.
Hey, here’s why I was having all the trouble: Symlinks. My WordPress installation has several different versions and I symlink my “wordpress” folder to point to the version that I want to test on. Unfortunately, that breaks a key function: plugin_basename().
More here: https://core.trac.www.ads-software.com/ticket/13550
Thanks again on the followup.
well spotted ??
- The topic ‘No date picker’ is closed to new replies.