diff --git a/controller/classes/Subtemplate.php b/controller/classes/Subtemplate.php index dcde733..854ac40 100644 --- a/controller/classes/Subtemplate.php +++ b/controller/classes/Subtemplate.php @@ -13,13 +13,15 @@ class Subtemplate { $id = $post->ID; $result = ''; - $subtemplates = get_field('subtemplate', $id); - $result = ''; - if( $subtemplates ) { - foreach ( $subtemplates as $subtemplate ) { - $subtemplateType = $subtemplate['subtemplate_type']; + if (have_rows('subtemplate',$id)) { + while (have_rows('subtemplate',$id)) { + the_row(); - $subtemplateTitle = $subtemplate['section_title']; + $subtemplateType = get_sub_field('subtemplate_type'); + + $subtemplateTitle = get_sub_field('section_title'); + + $subtemplate = ''; switch ($subtemplateType) { case 'featurecircles': @@ -52,68 +54,95 @@ class Subtemplate { case 'team': $result .= $this->team($subtemplate,$subtemplateTitle); break; - - + case 'content': + $result .= $this->content($subtemplate,$subtemplateTitle); + break; + case 'faq': + $result .= $this->faq($subtemplate,$subtemplateTitle); + break; + case 'careers': + $result .= $this->careers($subtemplate,$subtemplateTitle); + break; + case 'mediadetail': + $result .= $this->mediaDetail($subtemplate,$subtemplateTitle); + break; } } - - return $result; } - return $result; } public function featureCircles($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function caseStudies($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function oldNew($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function productOverview($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function blueBox($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function createAccount($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function galleries($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function blogFeatures($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function mediaFeature($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } public function team($subtemplate,$subtemplateTitle) { $result = ''; - return result; + return $result; } + public function content($subtemplate,$subtemplateTitle) { + $result = ''; + $result .= get_sub_field('content'); + return $result; + } + public function faq($subtemplate,$subtemplateTitle) { + $result = ''; + + return $result; + } + public function careers($subtemplate,$subtemplateTitle) { + $result = ''; + + return $result; + } + public function mediaDetail($subtemplate,$subtemplateTitle) { + $result = ''; + + return $result; + } } \ No newline at end of file diff --git a/functions.php b/functions.php index 77efe46..393a443 100644 --- a/functions.php +++ b/functions.php @@ -38,9 +38,9 @@ remove_action( 'wp_head', 'print_emoji_detection_script', 7 ); remove_action( 'admin_print_scripts', 'print_emoji_detection_script' ); remove_action( 'wp_print_styles', 'print_emoji_styles' ); remove_action( 'admin_print_styles', 'print_emoji_styles' ); - -//ACF Collapser temp fix -add_filter('acf/compatibility/field_wrapper_class', '__return_true'); +// +////ACF Collapser temp fix +//add_filter('acf/compatibility/field_wrapper_class', '__return_true'); // TURN ON ACF SETTINGS PAGE if( function_exists('acf_add_options_page') ) { @@ -62,7 +62,7 @@ add_action( 'init', 'wpcodex_add_excerpt_support_for_pages' ); //Register Navigation function register_primary_nav_menu() { - register_nav_menu('header-menu',__( 'Primary Navigation Menu' )); - register_nav_menu('research-menu',__( 'Research Areas Menu' )); + register_nav_menu('landing-menu',__( 'Product Tour Navigation Menu' )); + register_nav_menu('general-menu',__( 'General Page Navigation Menu' )); } add_action( 'init', 'register_primary_nav_menu'); \ No newline at end of file diff --git a/template-events.php b/template-events.php new file mode 100644 index 0000000..a232f09 --- /dev/null +++ b/template-events.php @@ -0,0 +1,5 @@ + - + \ No newline at end of file diff --git a/template.php b/template.php new file mode 100644 index 0000000..05dd3a9 --- /dev/null +++ b/template.php @@ -0,0 +1,24 @@ + + +
+
+ + +
+
+ + + + \ No newline at end of file