mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-04-25 04:13:44 +03:00

This starts to address several items in the roadmap, but probably doesn't fully address any of them. It takes the plugin code that was written several months ago, before the scope of this project was fully sorted out, and refactors it to be a starting point for the roadmap. * Adds template files for form inputs that can be used to both create new pledges and manage existing pledges * Does some validation and sanitization work on form submissions * Adds a custom post status for deactivated pledges
52 lines
1.1 KiB
PHP
52 lines
1.1 KiB
PHP
<?php
|
|
namespace WordPressDotOrg\FiveForTheFuture\View;
|
|
|
|
/** @var bool $editable */
|
|
/** @var array $data */
|
|
?>
|
|
|
|
<div class="form-field">
|
|
<label for="5ftf-org-name">
|
|
<?php esc_html_e( 'Organization Name', 'wordpressorg' ); ?>
|
|
</label>
|
|
<input
|
|
type="text"
|
|
class="large-text"
|
|
id="5ftf-org-name"
|
|
name="org-name"
|
|
value="<?php echo esc_attr( $data['org-name'] ); ?>"
|
|
required
|
|
<?php echo ( $editable ) ? '' : 'readonly'; ?>
|
|
/>
|
|
</div>
|
|
|
|
<div class="form-field">
|
|
<label for="5ftf-org-url">
|
|
<?php esc_html_e( 'Website Address', 'wordpressorg' ); ?>
|
|
</label>
|
|
<input
|
|
type="url"
|
|
class="large-text"
|
|
id="5ftf-org-url"
|
|
name="org-url"
|
|
value="<?php echo esc_attr( $data['org-url'] ); ?>"
|
|
required
|
|
<?php echo ( $editable ) ? '' : 'readonly'; ?>
|
|
/>
|
|
</div>
|
|
|
|
<div class="form-field">
|
|
<label for="5ftf-org-description">
|
|
<?php _e( 'Organization Blurb', 'wordpressorg' ); ?>
|
|
</label>
|
|
<textarea
|
|
class="large-text"
|
|
id="5ftf-org-description"
|
|
name="org-description"
|
|
required
|
|
<?php echo ( $editable ) ? '' : 'readonly'; ?>
|
|
>
|
|
<?php echo esc_html( $data['org-description'] ); ?>
|
|
</textarea>
|
|
</div>
|