-
Notifications
You must be signed in to change notification settings - Fork 331
Open
Labels
Description
The previous approach was not favourable as it is complex for the users.
User flow:
- User clicks "Add Contest" in the admin menu
- Enters just the contest title
- Clicks "Create Contest"
- WordPress creates a new page with all the content from the template
- This page is accessible in the pages of admin section and can be editable.
- User clicks "Edit it here" and can modify the content using the familiar WordPress block editor
Features to be added:
- User can have the option to select among multiple templates
- Start and end date with dynamic fields
- Redirect directly to editor after creation
- improve security and prevent Cross-Site Request Forgery (CSRF)
- Hide sections; Grand Prize Winners and Finalist Winners when creating contest #375
- Help menu can be added for tutorials (documentation/Video) for creating a contest
Reference Documentation:
add_menu_page()- https://developer.wordpress.org/reference/functions/add_menu_page/submit_button()- https://developer.wordpress.org/reference/functions/submit_button/sanitize_text_field()- https://developer.wordpress.org/reference/functions/sanitize_text_field/$wpdb (WordPress Database Class)- https://developer.wordpress.org/reference/classes/wpdb/