I'm using the Contact Form plugin on my site and I like it. Now I want to add an additional version of a contact form on my site that's configured specifically for RSVPs, i.e. add fields for number of guests attending, have a link to "RSVP Form configuration" appear on my dashboard, etc.
I tried duplicating the folder manage/plugins/iu-contact-form, renaming it to iu-rsvp-form and manipulating each file in the folder so that all instances in source code of 'contact-form' were changed to 'rsvp-form' -- but doing this broke my site.
Is there a different way to accomplish what I'm trying to do? Is it possible to have different configurations of forms from one plugin download?
You should be able to copy contact form folder to rsvp-form but you will need to change function names also (next to the paths you already renamed). For example, all functions in contact form plugin start with "iucontactf_"
So there are several functions but one of them is iucontactf_display_form (used to change IU conent on-the-fly just before it is displayed to the user and to replace [contact-form] tag with actual form). You should replace it with e.g. rsvpf_display_form, and also, at the end of contactform.plugin.php (which would be rsvpform.plugin.php in your case) there is a hook for content: add_hook('content','iucontactf_display_form');
You should change it to: add_hook('content','rsvpf_display_form'); (as well as all function names, of course)
Also, there are some JavaScript functions (file contact-form.js.php) which start with "cform_" - you should rename those too (and their calls in the code) as neither PHP nor JS allow two functions with same name to exist at the same time.
Got it, Nemanja. Thank you for the advice. I'm interested in hiring CubeScripts to do this for me; could you provide an estimate for the fee? Email me at [my-forum-username] (at) gmail (dot) com
Please use http://www.cubescripts.com/contact.php to contact us. Explain in details what do you need to be done and someone (maybe even me) will contact you soon.