**this project will be used to improve transparency and accountability in the Philippines typhoon response**
Wanted: Wordpress Plugin/PHP Development Work (a plugin that meets all the acceptance criteria in this posting)
Core skills: Wordpress plugin development, php, familiarity with Wordpress hooks, familiarity with Agile/Scrum terminology a plus
PLUGIN NAME: smart_response
Custom Post Types we are using:
1. Organizations <organizations>
2. Disasters <disasters>
3. Response to Disasters Surveys <response_surveys>
Story: As a user, I need to be able to go to the register page and enter my registration information. I should be able to use a select box to select the organization I represent, and if the organization is not already in the select box, I should be able to input the organization name. All fields should be required. If I submit the form without completing a field, I should see an error message indicating what field is still outstanding. There should be a warning below the form that displays what my IP address is and letting me know that my IP address will be recorded with my registration answers. I should also need to check a checkbox that says I agree to the terms and conditions of the website. The terms should be hyperlinked to /termsandconditions. Finally I should complete a CAPTCHA form in order to submit my form.
Acceptance Criteria:
1. All fields specified in the Acceptance Criteria are required. Form should not submit if any are not completed and the checkbox is not selected.
2. Upon successful completion, all the fields should be added to the user's meta data and an email should be sent to (email address to be provided) notifying of new user registration.
3. IP address should be recorded and added to the user meta data.
4. If user's email has already been registered as a user of this system, then error message should be returned indicating as such and no data should be added to the database.
5. CAPTCHA Form should be added to the end of the form and user should not be allowed to post data if CAPTCHA is not successfully completed (using a plugin is OK)
6. Organization select menu options are driven by a query to the custom post type organizations. No limit to number of posts. The value and the text displayed should be the title of the organization post. Do not show post if the title is empty, and skip to the next one.
7. If user has added a new organization, a validation should be done to ensure the organization was not in the list that populated the select box from #6. If it is in the list, an error message should indicate as such.
8. After successful completion with a new organization inputted, a new post of custom type organizations should be created, authored by the new user with the title of the post being the organization user entered into input. It should not be in a published state (preview) upon creation. It should only be editable by admins and the new user.
9. The new user's custom role type should be survey_responder.
10. Form fields for the registration form include:
a. First Name
b. Last Name
c. email address
d. organization
e. ip_address (hidden)
f. phone_number
g. terms_conditions