mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-06 18:55:44 +03:00
Remove shortcode, add button & dialog by hooking into actions
This commit is contained in:
parent
a67ef04505
commit
04d1a12296
6 changed files with 88 additions and 94 deletions
|
@ -14,7 +14,6 @@ defined( 'WPINC' ) || die();
|
|||
// Todo make this into simple optionless blocks instead?
|
||||
add_shortcode( '5ftf_pledge_form_new', __NAMESPACE__ . '\render_form_new' );
|
||||
add_shortcode( '5ftf_pledge_form_manage', __NAMESPACE__ . '\render_form_manage' );
|
||||
add_shortcode( '5ftf_pledge_form_manage_link', __NAMESPACE__ . '\render_manage_link_request' );
|
||||
|
||||
/**
|
||||
* Render the form(s) for creating new pledges.
|
||||
|
@ -175,19 +174,6 @@ function render_form_manage() {
|
|||
return ob_get_clean();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Render the `render_manage_link_request` shortcode.
|
||||
*/
|
||||
function render_manage_link_request() {
|
||||
// @todo enable when https://github.com/WordPress/five-for-the-future/issues/6 is done
|
||||
if ( ! defined( 'WPORG_SANDBOXED' ) || ! WPORG_SANDBOXED ) {
|
||||
return;
|
||||
}
|
||||
|
||||
require_once FiveForTheFuture\get_views_path() . 'form-pledge-request-manage-link.php';
|
||||
}
|
||||
|
||||
/**
|
||||
* Process a submission from the Manage Existing Pledge form.
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue