Changeset 2786482
- Timestamp:
- 09/18/2022 06:00:37 AM (4 years ago)
- Location:
- reservation-form
- Files:
-
- 4 edited
-
tags/1.0.0/assets/css/frontend_style_css.css (modified) (3 diffs)
-
tags/1.0.0/oopspk_reservation_form_optionpage.php (modified) (5 diffs)
-
trunk/assets/css/frontend_style_css.css (modified) (3 diffs)
-
trunk/oopspk_reservation_form_optionpage.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
reservation-form/tags/1.0.0/assets/css/frontend_style_css.css
r2786417 r2786482 1 1 .input_box { 2 width: 100% !important;3 padding: 12px !important;4 border: 1px solid # 000 !important;5 border-radius: 4px !important;6 resize: vertical !important;2 width: 100%; 3 padding: 12px; 4 border: 1px solid #ccc; 5 border-radius: 4px; 6 resize: vertical; 7 7 } 8 8 … … 29 29 30 30 .container { 31 border-radius: 5px !important;32 background-color: #fff !important;33 padding: 20px !important;31 border-radius: 5px; 32 background-color: #fff; 33 padding: 20px; 34 34 } 35 35 36 36 .col-25 { 37 float: left !important;38 width: 25% !important;39 margin-top: 6px !important;37 float: left; 38 width: 25%; 39 margin-top: 6px; 40 40 } 41 41 42 42 .col-75 { 43 float: left !important;44 width: 75% !important;45 margin-top: 6px !important;43 float: left; 44 width: 75%; 45 margin-top: 6px; 46 46 } 47 47 … … 56 56 @media screen and (max-width: 600px) { 57 57 .col-25, .col-75, .submit_customization { 58 width: 100% !important;59 margin-top: 0 !important;58 width: 100%; 59 margin-top: 0; 60 60 } 61 61 } -
reservation-form/tags/1.0.0/oopspk_reservation_form_optionpage.php
r2786417 r2786482 7 7 8 8 //create new top-level menu 9 add_menu_page('Reservation Form 7', 'Reservation Form', 'administrator', wp_reservation_dir, 'oopspkreservation_form_settings_page' , '' );9 add_menu_page('Reservation Form 7', 'Reservation Form', 'administrator', __FILE__, 'oopspkreservation_form_settings_page' , '' ); 10 10 11 add_submenu_page( 'my-top-level-slug', 'My Custom Page', 'My Custom Page',12 'manage_options', 'my-top-level-slug');13 11 14 12 //call register settings function 15 13 add_action( 'admin_init', 'oopspkreservation_form_plugin_settings' ); 16 }17 18 add_action('admin_menu', 'oopspk_register_my_custom_submenu_page');19 20 function oopspk_register_my_custom_submenu_page() {21 22 add_submenu_page(23 'reservation-form',24 'entries',25 'Entries',26 'manage_options',27 'entries',28 'oopspk_my_custom_submenu_page_callback' );29 14 } 30 15 … … 39 24 require(wp_reservation_dir."/inc/submit_add_options.php"); 40 25 require(wp_reservation_dir."/inc/submit_add_more_fields.php"); 41 require(wp_reservation_dir."/inc/submit_delete.php");42 require("oopspk_entries.php");43 44 26 } 45 46 27 function oopspkreservation_form_settings_page() { 47 28 ?> … … 54 35 <!-- Tab 1 --> 55 36 <input type="radio" name="tabset" id="tab1" aria-controls="marzen" checked> 56 <label for="tab1"> Dashboard</label>37 <label for="tab1">Customization</label> 57 38 <!-- Tab 2 --> 58 39 <input type="radio" name="tabset" id="tab2" aria-controls="rauchbier"> … … 60 41 <!-- Tab 3 --> 61 42 <input type="radio" name="tabset" id="tab3" aria-controls="dunkles"> 62 <label for="tab3"> --</label>43 <label for="tab3">Entries</label> 63 44 64 45 <div class="tab-panels"> 65 46 <section id="marzen" class="tab-panel" > 66 <h2> Dashboard</h2>47 <h2>Customization</h2> 67 48 <div style="float: right; margin-bottom: 10px;"> 68 49 Shortcode: <input value="[oops_wp_reservation_form_shortcode]" style="width: 250px; height: 40px;"> … … 75 56 </section> 76 57 <section id="dunkles" class="tab-panel"> 77 58 <h2>Entries</h2> 59 <?php 60 //$results = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}options WHERE option_id = 1", OBJECT ); 61 global $wpdb; 62 $results = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}reservation_entries ORDER BY `id` DESC ", OBJECT ); 63 //var_dump($results); 64 ?> 65 66 <table class="wp-list-table widefat fixed posts" style="margin-bottom:10px;"> 67 <thead> 68 <tr> 69 <th style="width: 5%">ID</th> 70 <th>Entries</th> 71 <th style="width: 10%">Action</th> 72 </tr> 73 </thead> 74 <tfoot> 75 <tr> 76 <th style="width: 5%">ID</th> 77 <th>Entries</th> 78 <th style="width: 10%">Action</th> 79 </tr> 80 </tfoot> 81 <tbody> 82 <?php 83 if(empty($results)){ 84 echo'<tr><td></td><td>No results found</td><tr>'; 85 } 86 foreach ($results as $key => $entries) { 87 ?> 88 <tr> 89 <td style="width: 5%"><?php echo $entries->id; ?></td> 90 <td><?php echo $entries->entries; ?></td> 91 <td style="width: 10%"><a href="#" style="color:red;"> Delete </a></td> 92 </tr> 93 <?php 94 } 95 ?> 96 </tbody> 97 </table> 78 98 </section> 79 99 </div> -
reservation-form/trunk/assets/css/frontend_style_css.css
r2786417 r2786482 1 1 .input_box { 2 width: 100% !important;3 padding: 12px !important;4 border: 1px solid # 000 !important;5 border-radius: 4px !important;6 resize: vertical !important;2 width: 100%; 3 padding: 12px; 4 border: 1px solid #ccc; 5 border-radius: 4px; 6 resize: vertical; 7 7 } 8 8 … … 29 29 30 30 .container { 31 border-radius: 5px !important;32 background-color: #fff !important;33 padding: 20px !important;31 border-radius: 5px; 32 background-color: #fff; 33 padding: 20px; 34 34 } 35 35 36 36 .col-25 { 37 float: left !important;38 width: 25% !important;39 margin-top: 6px !important;37 float: left; 38 width: 25%; 39 margin-top: 6px; 40 40 } 41 41 42 42 .col-75 { 43 float: left !important;44 width: 75% !important;45 margin-top: 6px !important;43 float: left; 44 width: 75%; 45 margin-top: 6px; 46 46 } 47 47 … … 56 56 @media screen and (max-width: 600px) { 57 57 .col-25, .col-75, .submit_customization { 58 width: 100% !important;59 margin-top: 0 !important;58 width: 100%; 59 margin-top: 0; 60 60 } 61 61 } -
reservation-form/trunk/oopspk_reservation_form_optionpage.php
r2786417 r2786482 7 7 8 8 //create new top-level menu 9 add_menu_page('Reservation Form 7', 'Reservation Form', 'administrator', wp_reservation_dir, 'oopspkreservation_form_settings_page' , '' );9 add_menu_page('Reservation Form 7', 'Reservation Form', 'administrator', __FILE__, 'oopspkreservation_form_settings_page' , '' ); 10 10 11 add_submenu_page( 'my-top-level-slug', 'My Custom Page', 'My Custom Page',12 'manage_options', 'my-top-level-slug');13 11 14 12 //call register settings function 15 13 add_action( 'admin_init', 'oopspkreservation_form_plugin_settings' ); 16 }17 18 add_action('admin_menu', 'oopspk_register_my_custom_submenu_page');19 20 function oopspk_register_my_custom_submenu_page() {21 22 add_submenu_page(23 'reservation-form',24 'entries',25 'Entries',26 'manage_options',27 'entries',28 'oopspk_my_custom_submenu_page_callback' );29 14 } 30 15 … … 39 24 require(wp_reservation_dir."/inc/submit_add_options.php"); 40 25 require(wp_reservation_dir."/inc/submit_add_more_fields.php"); 41 require(wp_reservation_dir."/inc/submit_delete.php");42 require("oopspk_entries.php");43 44 26 } 45 46 27 function oopspkreservation_form_settings_page() { 47 28 ?> … … 54 35 <!-- Tab 1 --> 55 36 <input type="radio" name="tabset" id="tab1" aria-controls="marzen" checked> 56 <label for="tab1"> Dashboard</label>37 <label for="tab1">Customization</label> 57 38 <!-- Tab 2 --> 58 39 <input type="radio" name="tabset" id="tab2" aria-controls="rauchbier"> … … 60 41 <!-- Tab 3 --> 61 42 <input type="radio" name="tabset" id="tab3" aria-controls="dunkles"> 62 <label for="tab3"> --</label>43 <label for="tab3">Entries</label> 63 44 64 45 <div class="tab-panels"> 65 46 <section id="marzen" class="tab-panel" > 66 <h2> Dashboard</h2>47 <h2>Customization</h2> 67 48 <div style="float: right; margin-bottom: 10px;"> 68 49 Shortcode: <input value="[oops_wp_reservation_form_shortcode]" style="width: 250px; height: 40px;"> … … 75 56 </section> 76 57 <section id="dunkles" class="tab-panel"> 77 58 <h2>Entries</h2> 59 <?php 60 //$results = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}options WHERE option_id = 1", OBJECT ); 61 global $wpdb; 62 $results = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}reservation_entries ORDER BY `id` DESC ", OBJECT ); 63 //var_dump($results); 64 ?> 65 66 <table class="wp-list-table widefat fixed posts" style="margin-bottom:10px;"> 67 <thead> 68 <tr> 69 <th style="width: 5%">ID</th> 70 <th>Entries</th> 71 <th style="width: 10%">Action</th> 72 </tr> 73 </thead> 74 <tfoot> 75 <tr> 76 <th style="width: 5%">ID</th> 77 <th>Entries</th> 78 <th style="width: 10%">Action</th> 79 </tr> 80 </tfoot> 81 <tbody> 82 <?php 83 if(empty($results)){ 84 echo'<tr><td></td><td>No results found</td><tr>'; 85 } 86 foreach ($results as $key => $entries) { 87 ?> 88 <tr> 89 <td style="width: 5%"><?php echo $entries->id; ?></td> 90 <td><?php echo $entries->entries; ?></td> 91 <td style="width: 10%"><a href="#" style="color:red;"> Delete </a></td> 92 </tr> 93 <?php 94 } 95 ?> 96 </tbody> 97 </table> 78 98 </section> 79 99 </div>
Note: See TracChangeset
for help on using the changeset viewer.