Events Made Easy › Forums › Tips › Add Events from Frontend, my solution
- This topic has 40 replies, 6 voices, and was last updated 13 years, 7 months ago by Anonymous.
-
AuthorPosts
-
Mon 28 Mar 2011 at 14:15 #42665AnonymousInactive
Hello.
i use the great plugin and i have add a small template to the Theme of WordPress to use a form inside frontedn to add events as Draft and the manager of this blog change the status.
Maybe you can see on my code and give me an feedback. I dont find for all requirements a function, so i uese a sql-query.
See here for my code: https://gist.github.com/890535
Thanks for feedback! maybe i can build a plugin for this, current it is only a template, fast and easy.
Mon 28 Mar 2011 at 17:14 #47326FrankyKeymasterthanks for the code! I’ll take a look at it and make a shortcode out of it as well
Mon 4 Apr 2011 at 19:54 #47327AnonymousInactiveFranky, i’m working on making this a plugin if you are interestedโฆ
Mon 4 Apr 2011 at 21:33 #47328FrankyKeymasterSure, very interested!
Mon 4 Apr 2011 at 21:41 #47329AnonymousInactivemalo.conny are you working on this as well? We might join efforts ๐
Mon 4 Apr 2011 at 21:49 #47330AnonymousInactive@halles: yes, nice. This snippet was my first version and current i have not enough time to create a plugin from null. Il ove the idea to create a addon plugin. Maybe we can developt via git and so it is possible to join as the ptoject.
Mon 4 Apr 2011 at 21:51 #47331AnonymousInactivemalo.conny you got any experience with mercurial? i have none with git. If not i can always try and learn git.
I’ll push the stuff somewhere tonight when i have a working first version.
Mon 4 Apr 2011 at 22:00 #47332AnonymousInactive@halles: git and svn is always an idea, please use your workflow for your development. Also you can send your first version per mail (via my blog: bueltge.de/impressum ) and i will check in git and test your version.
Thanks for your work.
Mon 4 Apr 2011 at 22:06 #47333FrankyKeymastergit is easy ๐
Btw: I was planning on beginning integration of the version malo.conny put up this week, but I realized it would need small enhancements concerning recurrent events and location management (the drop-down option for locations should be honoured). But I can always integrate your changes in the main plugin, or assist in any way for a addon plugin.
Tue 5 Apr 2011 at 08:07 #47334AnonymousInactiveNo working version so farโฆ spent most of the time creating templatable structures, data validation, errors, etc. The Locations part is not implemented yetโฆ I need to get this first part working for the project i’m working on. Once that is done, i’ll dive into the Locations part of the form.
There a big bunch of stuff i still need to do.
Check it out at: http://x.halles.cl/d0c7108e.zip
Night!
Tue 5 Apr 2011 at 11:31 #47335AnonymousInactive@halles: i will see for this version and give feedback; i have here the lunch time ๐
Tue 5 Apr 2011 at 15:54 #47336AnonymousInactivewow guys!
This is just where I am looking for. I tried the form of Malo.conny and it worked. Only the date-picker didnโt work ( I put the js in my theme folder). What did I do wrong?
And it would be nice if it was possible to upload images.
I am looking forward to see the new plugin.
Thanks
Tue 5 Apr 2011 at 17:00 #47337AnonymousInactiveIt seems better to integrate this into EME so future changes won’t break compatibility.
Tue 5 Apr 2011 at 17:04 #47338FrankyKeymasterI agree that it would be better to put in the source, but I can offer any help needed.
Tue 5 Apr 2011 at 17:25 #47339AnonymousInactive@marijke: i think you haven not right include the files of datepicker in the right folder, its not in my source on gist. I can send you my version via mail, but you must send me an mail for your adress. You find my mail on bueltge.de/impressum
Tue 5 Apr 2011 at 21:49 #47340AnonymousInactive@admintiger, @Franky: for the moment i would prefer to keep this separated from EME since it’s a work in progress, but a small release version should be ready soon. This way we wouldn’t have to wait for plugin releases for this plugin to update.
I’ve been working on the code so it will be compatible at templating level with EME (through the admin), but also let it be templatable through the theme (which is the default now because of my inmediate needs). This because, for me at least, it’s valuable to have control over what i deliver to clients when working on a non-blog theme; which I think could be interesting to implement in EME as wellโฆ
Let me know what you think ๐
Tue 5 Apr 2011 at 22:08 #47341FrankyKeymasterNo problem either way, I’m always glad when someone lends a hand ๐
Mon 11 Apr 2011 at 19:00 #47342AnonymousInactiveHi,
With help of the code of malo.conny I succeeded to get a form working. It is not perfect yet (will it ever be?)
I miss some fields in events like telephone, e-mailaddress and address of the contactperson. You will need those fields if people fill in the form on the frontend without login.
And I would be nice if users can upload pictures.
So lots of wishes here. May be I can help testing?
Mon 11 Apr 2011 at 20:57 #47343AnonymousInactiveI need that capability and would be pleased to help with testing. Is the current version available for download?
P.S. I noticed malo.conny’s instruction about how to contact him after I posted this, so I will do that.
Fri 15 Apr 2011 at 00:34 #47344AnonymousInactiveHi, I’m also very interested in a front-end part to let (registered) users add events.
It would be great if it is possible to select (as admin) which Roles can add (and maybe also adjust) events through the front-end, to keep it as general as possible.
If I can help out in any way, please let me know!
I only found out about EME today and am so happy to have found such an extensive and active plugin.. wow! ๐ So even if the development will take a while, big thanks to everyone who works on it!
Fri 15 Apr 2011 at 06:52 #47345AnonymousInactive@halles: sorry for waiting, i dont now not enough time to test the plugin ๐ Maybe you can give an URL for the readers here and she test it also and give feedback.
Sun 17 Apr 2011 at 19:08 #47346AnonymousInactiveHey guys, sorry i’ve been buried with work, plus having to deliver the project which uses the plugin, all this in spanish :p But i got it working now, messaged back to english, and pushed it to a repo and all (sorry, didn’t find the time to setup git ATM):
https://bitbucket.org/halles/events-manager-extended-frontend-submit/
Currently it is only capturing data for the event, not the location.
Let me know if your tests are succesful! ๐
Sun 17 Apr 2011 at 19:10 #47347AnonymousInactiveOh, i have it actually working live at http://www.eligevivirsano.cl/eventos/agregar-un-evento (it’s in spanish)
Sun 17 Apr 2011 at 20:11 #47348AnonymousInactiveThanks for sharing your plugin. I haven’t tried it yet, but noticed that the “events-manager-extended-frontend-submit.php” file needs a PHP closing tag “?>” at the end.
Sun 17 Apr 2011 at 20:40 #47349AnonymousInactiveI have only used your plug-in a few minutes. There could be problems I haven’t noticed yet, but it seems to work as expected. It activated normally in WP. I put a [submit_event_form] shortcode on a new WP event submission page and successfully submitted a test event.
Most users obviously will need the additional capability to submit location information, but what you have now will meet the needs of some users and is a good start for those of us who need more. Thanks again for making it available.
Sun 17 Apr 2011 at 20:54 #47350AnonymousInactiveI don’t know what I did differently that caused the problem, but the second test event submission resulted in these two error messages:
WordPress database error: [Incorrect integer value: '' for column 'location_id' at row 1]
INSERT INTO <code>wp_dbem_events</code> (<code>event_name</code>,<code>event_status</code>,<code>event_start_date</code>,<code>event_end_date</code>,<code>event_start_time</code>,<code>event_end_time</code>,<code>event_rsvp</code>,<code>rsvp_number_days</code>,<code>registration_requires_approval</code>,<code>registration_wp_users_only</code>,<code>event_seats</code>,<code>event_contactperson_id</code>,<code>event_notes</code>,<code>event_page_title_format</code>,<code>event_single_event_format</code>,<code>event_contactperson_email_body</code>,<code>event_respondent_email_body</code>,<code>event_url</code>,<code>event_category_ids</code>,<code>event_attributes</code>,<code>location_id</code>,<code>creation_date</code>,<code>modif_date</code>,<code>creation_date_gmt</code>,<code>modif_date_gmt</code>) VALUES ('Test Event','5','2011-04-30','2011-04-30','20:00:00','23:00:00','0','0','0','0','0','-1','This will be a great event.','','','someone@hotmail.com','','http://www.domain.com','2','a:0:{}','','2011-04-17 20:48:51','2011-04-17 20:48:51','2011-04-17 20:48:51','2011-04-17 20:48:51')
WordPress database error: [Incorrect integer value: '' for column 'location_id' at row 1]
INSERT INTO <code>wp_dbem_events</code> (<code>event_name</code>,<code>event_status</code>,<code>event_start_date</code>,<code>event_end_date</code>,<code>event_start_time</code>,<code>event_end_time</code>,<code>event_rsvp</code>,<code>rsvp_number_days</code>,<code>registration_requires_approval</code>,<code>registration_wp_users_only</code>,<code>event_seats</code>,<code>event_contactperson_id</code>,<code>event_notes</code>,<code>event_page_title_format</code>,<code>event_single_event_format</code>,<code>event_contactperson_email_body</code>,<code>event_respondent_email_body</code>,<code>event_url</code>,<code>event_category_ids</code>,<code>event_attributes</code>,<code>location_id</code>,<code>creation_date</code>,<code>modif_date</code>,<code>creation_date_gmt</code>,<code>modif_date_gmt</code>) VALUES ('Test Event','5','2011-04-30','2011-04-30','20:00:00','23:00:00','0','0','0','0','0','-1','This will be a great event.','','','someone@hotmail.com','','http://www.domain.com','2','a:0:{}','','2011-04-17 20:48:51','2011-04-17 20:48:51','2011-04-17 20:48:51','2011-04-17 20:48:51')Sun 17 Apr 2011 at 21:12 #47351AnonymousInactiveNote that bbpress replaced back-quote characters in the above error messages alternately with code open and close tags. I tried to correct that problem by escaping those characters, but bbpress doesn’t seem to support that.
Mon 18 Apr 2011 at 02:11 #47352AnonymousInactive@admintiger did you re-submit a with-errors submission by any chance? This could be happening because of the default values the process has setup, but i can’t reproduce it properly yetโฆ kind of in the middle of something :3
Tue 19 Apr 2011 at 18:07 #47353AnonymousInactive@halles, what a great job you did! Nice clean code.
I got the plugin working. I had a small problem: I took the folder: halles-events-manager-extended-frontend-submit-daac0e3b7dcb like in the zip-file. But the css-file was not found. It had to be in the folder:halles-events-manager-extended-frontend-submit.
My form looks like this(dutch). The error handling is not good yet. I based it on the form from malo.conny, but I am not a php-programmer. I am very happy with your plugin. I would like to combine the two. But I got into trouble with the time. I liked the way malo.conny did it (you can see it in my form), but you choose different for your time. Did you have a specific reason to do so?
Another thing I noticed: Like malo.conny you used the field โevent_contactperson_email_bodyโ for the email address of the contact person. I think it is not the right field. It is meant for the email text when people use RSVP. Malo.conny uses it only temporary, he adds the contact e-mail to the description. But you write it in that actual field, so it will be overwritten when people want to use the RSVP later.
I needed more fields like for example toegangsprijs( = price ). I add them direct from the form to the notes-field and it works fine for me that way.
Sat 23 Apr 2011 at 07:11 #47354AnonymousInactiveHey ๐
@marijke yeah, one has to remove the hash that tracker adds to the package. The plugin directory has to be “events-manager-extended-frontend-submit” for the plugin to work. For the time picker, i chose to do it that way because the events manager extended plugin (eme) uses that library and not the one malo.conny used. The idea (or at least mine) is to keep this plugin as integrated as i can with eme, so i’m just using the libs that come with eme. I like as well how malo.conny did it, maybe we could ask @Franky to use that one as well ๐ And as for the last question, i coded the plugin as fast as i could cause i needed it working quickly for delivery :p I’m trying to figure out a good way to integrate custom attributes easily into the form, but i’d rather focus first on the regular stuff eme supportsโฆ and because of that i just used the rsvp for catching the mail since the project i was working on didn’t need the rsvp part anyway, but it is not supposed to go in there indeed.
@admintiger i couldn’t reproduce the error you showed me above :/
Finally, I moved the plugin into github as i wanted so malo.malo conny can contribute as wellโฆ so the new address is:
https://github.com/halles/events-manager-extended-frontend-submit/
I have no plans on moving it againโฆ sorry for the inconvinience.
I think it would be better to keep the issues and feature requests over at github as well, but i’m not sure. In the meantime i’l try to keep track of the feedback on this forum. If you want to report these on github i’ll be more than welcome since a forum thread will get messy over time.
I’m currently implementing the locations processing in the form, trying to use eme’s javascript and all, but i can’t make it work yet. What data should eventuful have in this part of the process? if anyone can gimme some support it would be great ๐
http://halles.bitplz.com/e17237dc.png
Night!
Sat 23 Apr 2011 at 08:28 #47355FrankyKeymaster@marijke: nice work!
@halles: I’m always open for improvements for the time picker (in fact I don’t like it now, so maybe I should switch over to the one used by malo.conny ๐ )
For the location processing: I am still planning on adding a status field there as well, so locations can be in draft also, and have an owner and such, but that’s for the future. The easiest way to implement locations would be just showing the location dropdown, but if you need any help, I can download your code and take a look at it.
Sat 23 Apr 2011 at 20:27 #47356AnonymousInactive@Franky let me know if you change any of those!
Sun 24 Apr 2011 at 06:43 #47357FrankyKeymasterI will, no worries ๐
Sun 24 Apr 2011 at 21:58 #47358AnonymousInactiveI’ve updated to 0.2.0 ๐ Check it out!
https://github.com/halles/events-manager-extended-frontend-submit
Also read the wiki pages on how to configure and playaround.
Have a great week!
Mon 25 Apr 2011 at 14:47 #47359AnonymousInactivehalles, I had unexpected shoulder surgery soon after installing your version 0.1 and wasn’t able to explore the database error issue previously reported. I am able to sit at a computer type with one hand now, so I installed 0.2.0 last night. I haven’t done much testing yet, but noticed that items in the drop-down category list-box are not selectable using Google Chrome or Safari. That problem doesn’t exist with IE, Firefox or Opera and therefore is probably a WebKit compatibility issue.
Tue 26 Apr 2011 at 10:15 #47360AnonymousInactive@halles, wow, you did it again! I am impressed. Nice that you even included google maps.
@admintiger,I had no problem with Safari or google chrome. Hope your shoulder will better quickly.
The dutch way of writing dates: dd-mm-yy is not possible in your frontend. And the datepicker is not translated as it is in the backend.
I added:
wp_register_script( ‘jquery-ui-datepicker-nl’, EME_PLUGIN_URL.’js/jquery-ui-datepicker/i18n/ui.datepicker-nl.js’, array(‘jquery-ui-core’));
and changed
wp_register_script( ’emefs’, WP_PLUGIN_URL.’/events-manager-extended-frontend-submit/emefs.js’, array(‘jquery-ui-datepicker’,’jquery-ui-datepicker-nl’, ‘jquery-timeentry’, ‘jquery-autocomplete’, ‘google-maps’));
and both problems were solved.
Tue 26 Apr 2011 at 12:41 #47361AnonymousInactive@marijke, the Safari/Chrome event category selection problem still exists here under Windows. However, I just tried Safari on a Mac and didn’t have the problem. Which operating system are you using?
Tue 26 Apr 2011 at 17:09 #47362AnonymousInactive@admintiger, I use windows vista.
Tue 26 Apr 2011 at 17:24 #47363AnonymousInactiveHey guys ๐ Thanks for all the testing!
@admintiger can you disable the stylesheet and test? I don’t think i’m doing anything with javascript on that input. Did you add a category? Maybe you could send me the html generated to check out why the input is not working to matias at halles.cl
@marijke i haven’t enabled localization yet, but what you did gives me a pretty good idea on how to do it. I’ll add it to the issues list ๐
And, i forgot to tell you that i updated to 0.3.0, i suppose you both tested with that one?
Thanks!!
Tue 26 Apr 2011 at 21:40 #47364AnonymousInactiveI am using 0.3.0.
I have four event categories.
Disabling the stylesheet did not correct the problem.
Disabling all other plugins did not correct the problem.
However, I copied the page HTML source to an HTML test page that is totally independent of WordPress and the drop-down listbox works correctly with all web browsers under Windows.
Following that test I freshly installed WordPress 3.1.2 at another domain, installed eme and emefs, created some test categories, and the drop-down listbox works correctly with all web browsers using the Twenty-Ten theme.
My theme at the original site that has the problem is a slightly-modified version of Twenty-Ten, but based on those tests either something I changed in that theme is causing the problem or option setting differences between the sites is causing it. Whatever the cause, it appears at this point that the problem probably is mine rather than yours. I will let you know what I find in the end.
Wed 27 Apr 2011 at 09:08 #47365AnonymousInactiveThe problem was found to be due to the following fix I had added to my theme style.css file to fix a well-known webkit animation bug:
html {
-webkit-animation:bugfix infinite 1s;
}
@-webkit-keyframes bugfix {
0% {zoom:1;}
100% {zoom:1;}
}I added that several weeks ago and had forgotten about it. It was only necessary to change the selector from html to the #id of a div where animation is being used to correct the problem. The emefs drop-down category selection listbox now works correctly with Chrome, Safari, Opera, Firefox and IE.
-
AuthorPosts
- The forum ‘Tips’ is closed to new topics and replies.