Changeset 4156 for sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments/views/sponsor-payment/main.php
- Timestamp:
- 09/28/2016 12:52:27 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments/views/sponsor-payment/main.php
r4155 r4156 6 6 7 7 <div id="container"> 8 <div id="content" class="wcorg-sponsor-payment" role="main">8 <div id="content" class="wcorg-sponsor-payment" role="main"> 9 9 10 <h1 class="entry-title">Sponsorship Payment</h1>10 <h1 class="entry-title">Sponsorship Payment</h1> 11 11 12 <?php if ( ! empty( $data['errors'] ) ) : ?>13 <?php foreach ( $data['errors'] as $error ) : ?>14 <p><strong>Error:</strong> <?php echo esc_html( $error ); ?></p>15 <?php endforeach; ?>16 <?php endif; ?>12 <?php if ( ! empty( $data['errors'] ) ) : ?> 13 <?php foreach ( $data['errors'] as $error ) : ?> 14 <p><strong>Error:</strong> <?php echo esc_html( $error ); ?></p> 15 <?php endforeach; ?> 16 <?php endif; ?> 17 17 18 <?php if ( $data['step'] == STEP_SELECT_INVOICE ) : ?>18 <?php if ( $data['step'] == STEP_SELECT_INVOICE ) : ?> 19 19 20 <p>Use this form to pay your WordCamp sponsorship fee to WordPress Community Support, PBC. If you did not receive an invoice ID yet, please get in touch with the event's Sponsorships Coordinator for more information.</p>20 <p>Use this form to pay your WordCamp sponsorship fee to WordPress Community Support, PBC. If you did not receive an invoice ID yet, please get in touch with the event's Sponsorships Coordinator for more information.</p> 21 21 22 <form method="POST">23 <input type="hidden" name="step" value="<?php echo STEP_SELECT_INVOICE; ?>" />24 <input type="hidden" name="sponsor_payment_submit" value="1" />22 <form method="POST"> 23 <input type="hidden" name="step" value="<?php echo STEP_SELECT_INVOICE; ?>" /> 24 <input type="hidden" name="sponsor_payment_submit" value="1" /> 25 25 26 <label>Event</label>27 <div class="control">28 <select name="wordcamp_id">29 <option value="" disabled selected>Select a WordCamp</option>30 <?php foreach ( $data['wordcamps'] as $wordcamp ) : ?>31 <option value="<?php echo esc_attr( $wordcamp->ID ); ?>"><?php echo esc_html( $wordcamp->post_title ); ?></option>32 <?php endforeach; ?>33 </select>34 </div>26 <label>Event</label> 27 <div class="control"> 28 <select name="wordcamp_id"> 29 <option value="" disabled selected>Select a WordCamp</option> 30 <?php foreach ( $data['wordcamps'] as $wordcamp ) : ?> 31 <option value="<?php echo esc_attr( $wordcamp->ID ); ?>"><?php echo esc_html( $wordcamp->post_title ); ?></option> 32 <?php endforeach; ?> 33 </select> 34 </div> 35 35 36 <label>Invoice ID</label>37 <div class="control">38 <input type="text" name="invoice_id" />39 </div>36 <label>Invoice ID</label> 37 <div class="control"> 38 <input type="text" name="invoice_id" /> 39 </div> 40 40 41 <label>Currency</label>42 <div class="control">43 <select name="currency">44 <option value="" disabled selected>Select a Currency</option>45 <?php foreach ( $data['currencies'] as $currency_key => $currency_name ) : ?>46 <option value="<?php echo esc_attr( $currency_key ); ?>">47 <?php echo esc_html( $currency_name ); ?>48 </option>49 <?php endforeach; ?>50 </select>51 </div>41 <label>Currency</label> 42 <div class="control"> 43 <select name="currency"> 44 <option value="" disabled selected>Select a Currency</option> 45 <?php foreach ( $data['currencies'] as $currency_key => $currency_name ) : ?> 46 <option value="<?php echo esc_attr( $currency_key ); ?>"> 47 <?php echo esc_html( $currency_name ); ?> 48 </option> 49 <?php endforeach; ?> 50 </select> 51 </div> 52 52 53 <label>Amount</label>54 <div class="control">55 <input type="text" name="amount" />56 </div>53 <label>Amount</label> 54 <div class="control"> 55 <input type="text" name="amount" /> 56 </div> 57 57 58 <div class="clear"></div>58 <div class="clear"></div> 59 59 60 <input type="submit" value="Continue" />61 </form>60 <input type="submit" value="Continue" /> 61 </form> 62 62 63 <?php elseif ( $data['step'] == STEP_PAYMENT_DETAILS ) : ?>63 <?php elseif ( $data['step'] == STEP_PAYMENT_DETAILS ) : ?> 64 64 65 <p>Please review the details below and hit "Make a Payment" when you're ready.</p>65 <p>Please review the details below and hit "Make a Payment" when you're ready.</p> 66 66 67 <table>68 <tr>69 <td>Invoice</td>70 <td><?php echo esc_html( $data['payment']['invoice_id'] ); ?></td>71 </tr>72 <tr>73 <td>Event</td>74 <td><?php echo esc_html( $data['payment']['wordcamp_obj']->post_title ); ?></td>75 </tr>76 <tr>77 <td>Currency</td>78 <td><?php echo esc_html( $data['payment']['currency'] ); ?></td>79 </tr>80 <tr>81 <td>Amount</td>82 <td><?php echo number_format( round( $data['payment']['amount'], 2 ), 2, '.', ' ' ); ?></td>83 </tr>84 </table>67 <table> 68 <tr> 69 <td>Invoice</td> 70 <td><?php echo esc_html( $data['payment']['invoice_id'] ); ?></td> 71 </tr> 72 <tr> 73 <td>Event</td> 74 <td><?php echo esc_html( $data['payment']['wordcamp_obj']->post_title ); ?></td> 75 </tr> 76 <tr> 77 <td>Currency</td> 78 <td><?php echo esc_html( $data['payment']['currency'] ); ?></td> 79 </tr> 80 <tr> 81 <td>Amount</td> 82 <td><?php echo number_format( round( $data['payment']['amount'], 2 ), 2, '.', ' ' ); ?></td> 83 </tr> 84 </table> 85 85 86 <form method="POST">87 <input type="hidden" name="step" value="<?php echo STEP_PAYMENT_DETAILS; ?>" />88 <input type="hidden" name="sponsor_payment_submit" value="1" />89 <input type="hidden" name="payment_data_json" value="<?php echo esc_attr( $data['payment_data_json'] ); ?>" />90 <input type="hidden" name="payment_data_signature" value="<?php echo esc_attr( $data['payment_data_signature'] ); ?>" />86 <form method="POST"> 87 <input type="hidden" name="step" value="<?php echo STEP_PAYMENT_DETAILS; ?>" /> 88 <input type="hidden" name="sponsor_payment_submit" value="1" /> 89 <input type="hidden" name="payment_data_json" value="<?php echo esc_attr( $data['payment_data_json'] ); ?>" /> 90 <input type="hidden" name="payment_data_signature" value="<?php echo esc_attr( $data['payment_data_signature'] ); ?>" /> 91 91 92 <script src="https://checkout.stripe.com/checkout.js" class="stripe-button"93 data-key="<?php echo esc_attr( $data['keys']['publishable'] ); ?>"94 data-amount="<?php echo esc_attr( round( $data['payment']['amount'], 2 ) * 100 ); ?>"95 data-currency="<?php echo esc_attr( $data['payment']['currency'] ); ?>"96 data-name="WordPress Community Support, PBC"97 data-description="Event Sponsorship Payment"98 data-image="https://stripe.com/img/documentation/checkout/marketplace.png"99 data-locale="auto"100 data-panel-label="Pay"101 data-label="Make a Payment"102 data-zip-code="true">103 </script>104 </form>92 <script src="https://checkout.stripe.com/checkout.js" class="stripe-button" 93 data-key="<?php echo esc_attr( $data['keys']['publishable'] ); ?>" 94 data-amount="<?php echo esc_attr( round( $data['payment']['amount'], 2 ) * 100 ); ?>" 95 data-currency="<?php echo esc_attr( $data['payment']['currency'] ); ?>" 96 data-name="WordPress Community Support, PBC" 97 data-description="Event Sponsorship Payment" 98 data-image="https://stripe.com/img/documentation/checkout/marketplace.png" 99 data-locale="auto" 100 data-panel-label="Pay" 101 data-label="Make a Payment" 102 data-zip-code="true"> 103 </script> 104 </form> 105 105 106 <?php elseif ( $data['step'] == STEP_PAYMENT_SUCCESS ) : ?>106 <?php elseif ( $data['step'] == STEP_PAYMENT_SUCCESS ) : ?> 107 107 108 <p><strong>Success!</strong> Your payment has been received, thank you!</p>108 <p><strong>Success!</strong> Your payment has been received, thank you!</p> 109 109 110 <ul>111 <li><a href="<?php echo esc_url( add_query_arg( 'again', 1 ) ); ?>">Make another payment</a></li>112 <li><a href="<?php echo esc_url( home_url( '/' ) ); ?>">Go back to Central</a></li>113 </ul>110 <ul> 111 <li><a href="<?php echo esc_url( add_query_arg( 'again', 1 ) ); ?>">Make another payment</a></li> 112 <li><a href="<?php echo esc_url( home_url( '/' ) ); ?>">Go back to Central</a></li> 113 </ul> 114 114 115 <?php endif; ?>115 <?php endif; ?> 116 116 117 </div><!-- #content -->117 </div><!-- #content --> 118 118 </div><!-- #container --> 119 119
Note: See TracChangeset
for help on using the changeset viewer.