This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Conditional Itinerary Builder Template | |
| $form_page = get_option('form_page'); | |
| $suggestions_page = get_option('suggestions_page'); | |
| $results_page = get_option('results_page); | |
| if ( is_page( $form_page ) ) { | |
| get_template_part('/templates/form-page'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action( 'init', 'ssm_remove_post_type_support' ); | |
| function ssm_remove_post_type_support() { | |
| remove_post_type_support( 'page', 'editor' ); | |
| } | |
| add_action( 'after_setup_theme', 'crb_load' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $args = array( | |
| 'post_type' => 'case-study', | |
| 'post_status' => 'publish', | |
| 'facetwp' => true, | |
| 'ssm' => true | |
| ); | |
| $query = new WP_Query( $args ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function pricing_plan_template( $plan, $display = 'full', $pricing_table_id ) { | |
| $features = get_field('features', $pricing_table_id); // list or curated | |
| if ( $features == 'list') { | |
| $available_features = get_field('standard_feature_list', $pricing_table_id); | |
| $standard_features = $plan['standard_features']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "key": "group_5888f0f081f23", | |
| "title": "Page Builder", | |
| "fields": [ | |
| { | |
| "key": "field_5888f0f5a2760", | |
| "label": "Content Blocks", | |
| "name": "content_blocks", | |
| "type": "flexible_content", | |
| "instructions": "<strong>Content Blocks<\/strong> are horizontal rows of content containing one or more columns.", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action ('genesis_before', 'ssm_do_hellobar'); | |
| /** | |
| * Create Hellobar | |
| * | |
| */ | |
| function ssm_do_hellobar() { | |
| if ( get_field('show_global_message') == 'Yes' && get_field('global_message', 'options') != NULL ) { | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if( function_exists('acf_add_local_field_group') ): | |
| acf_add_local_field_group(array ( | |
| 'key' => 'group_5436e219da3a2', | |
| 'title' => 'Layout Builder', | |
| 'fields' => array ( | |
| array ( | |
| 'key' => 'field_5436e27cb585e', | |
| 'label' => 'Content Blocks', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script> | |
| gform.addFilter( 'gform_datepicker_options_pre_init', function( optionsObj, formId, fieldId ) { | |
| if ( formId == 2 && fieldId == 5 ) { | |
| optionsObj.dateFormat = 'mm-dd-yy'; | |
| } | |
| return optionsObj; | |
| }); | |
| </script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Returns the first instance of a given layout option | |
| * @param - $id - the id of the post you are trying to target: '' by default | |
| * @param - $fc_field - the name of the ACF flexible field: 'content_blocks' as the default | |
| * @param - $fc_layout - the name of the flexible content layout: 'visual_editor' as the default | |
| * @return - mixed | |
| * @todo - test different types of returned content. at the moment, I am only using this for returning a string | |
| */ | |
| function get_first_instance_of_content_block( $id = '', $fc_field = 'content_blocks', $fc_layout = 'visual_editor' ) { | |