Allows to change initial set up of booking calendar. Usage example:
window.JetPlugins.hooks.addFilter( "jet-booking.input.config", "jetBooking", ( config ) => {
const validateDay = config.beforeShowDay;| // Client editing disclaimer | |
| function custom_admin_notice_with_logo() { | |
| $user_id = get_current_user_id(); | |
| if (get_user_meta($user_id, 'custom_notice_dismissed', true) !== 'yes') { | |
| if (current_user_can('administrator') || current_user_can('editor') || current_user_can('author')) { | |
| $nonce = wp_create_nonce('custom_notice_dismiss_nonce'); | |
| $image_url = 'https://nerdrush.com/wp-content/uploads/2023/08/Nerd-Rush-Logo-Blue-2023.svg'; // External image URL | |
| ?> | |
| <div class="notice notice-warning custom-notice" style="padding-top: 20px;"> | |
| <img src="<?php echo esc_url( $image_url ); ?>" alt="Logo" style="width: 120px; display: block; margin-bottom: 10px;"> |
| <?php | |
| //You may just use get_post_meta() / get_term_meta() / get_user_meta() to get post/term/user meta | |
| //However, in Listing Grid, you may use get_meta() method for convenience | |
| $value = jet_engine()->listings->data->get_meta( $meta_key, $object ); | |
| /** | |
| * Get object meta value. Works for Posts, Terms, Users, Comments | |
| * $object defaults to null, then the value will be retrieved from the current listing object |
| /** ----------- Grid Shortcodes I use Most Often ---------- */ | |
| [grid content="post"] | |
| [grid content="post" columns="4"] | |
| [grid content="post" categories="16, 7"] | |
| [grid content="post" content_limit="50"] |
| {"type":"form","data":{"fields":[{"id":"section-1","element_id":"section-1","form_id":"wrapper-1537827779502-1868","condition_action":"show","condition_rule":"any","conditions":[],"type":"section","options":[],"cols":12,"section_title":"Project Leader","section_border":"false","section_subtitle":"","custom-class":"","wrapper_id":"wrapper-1537827779502-1868"},{"id":"name-1","element_id":"name-1","form_id":"wrapper-1511347711918-1669","condition_action":"show","condition_rule":"any","conditions":[],"type":"name","cols":4,"required":"true","field_label":"Project Leader Name","placeholder":"E.g. John","prefix_label":"Prefix","fname_label":"First Name","fname_placeholder":"E.g. John","mname_label":"Middle Name","mname_placeholder":"E.g. Smith","lname_label":"Last Name","lname_placeholder":"E.g. Doe","prefix_description":"","fname_description":"","mname_description":"","lname_description":"","description":"","custom-class":"","wrapper_id":"wrapper-1511347711918-1669"},{"id":"email-1","element_id":"email-1","form_id |
| <?php | |
| /** | |
| * Style pagination to look like Genesis. | |
| * | |
| * @version 1.0.0 | |
| * | |
| * @author Mike Hemberger @JiveDig | |
| * | |
| * @link https://gist.github.com/JiveDig/b9810ba4c322d7757993159ed9ccb61f |
| <?php | |
| // Flush rewrite rules after switch theme | |
| function my_rewrite_flush() { | |
| flush_rewrite_rules(); | |
| } | |
| add_action( 'after_switch_theme', 'my_rewrite_flush' ); | |
| // A little help so we can get the stylesheet from parent theme | |
| // Remove line 10-19 if this is not a child theme | |
| function my_enqueue_styles() { |
| <?php | |
| // Add to functions.php | |
| function fwp_combine_sources( $params, $class ) { | |
| if ( 'MY_FACET_NAME' == $params['facet_name'] ) { | |
| $value = get_field( 'YOUR_FIELD_1' ); | |
| $params['facet_value'] = sanitize_title( $value ); | |
| $params['facet_display_value'] = $value; | |
| $class->insert( $params ); |
| <?php | |
| $terms = array( 'citywide', 'central', 'east', 'west', 'seasonal' ); | |
| foreach( $terms as $term ) { | |
| $events = tribe_get_events( | |
| array( | |
| 'posts_per_page' => 4, | |
| 'tax_query' => array( | |
| array( | |
| 'taxonomy' => 'tribe_events_cat', |