stuff
Signed-off-by: Jeff <jeff@gotenzing.com>
Showing
11 changed files
with
64 additions
and
134 deletions
| ... | @@ -17387,8 +17387,12 @@ ul.sf_date_field .sf-datepicker { | ... | @@ -17387,8 +17387,12 @@ ul.sf_date_field .sf-datepicker { |
| 17387 | #page-wrapper .breadcrumb { | 17387 | #page-wrapper .breadcrumb { |
| 17388 | margin-bottom: 0px; | 17388 | margin-bottom: 0px; |
| 17389 | } | 17389 | } |
| 17390 | #page-wrapper .breadcrumb #breadcrumb { | 17390 | #page-wrapper .breadcrumb a { |
| 17391 | margin-bottom: 10px; | 17391 | text-decoration: none; |
| 17392 | text-transform: capitalize; | ||
| 17393 | } | ||
| 17394 | #page-wrapper .breadcrumb span { | ||
| 17395 | margin: 0px 10px; | ||
| 17392 | } | 17396 | } |
| 17393 | #page-wrapper h1, #page-wrapper .h1 { | 17397 | #page-wrapper h1, #page-wrapper .h1 { |
| 17394 | font-size: 45px; | 17398 | font-size: 45px; |
| ... | @@ -17691,11 +17695,18 @@ ul.sf_date_field .sf-datepicker { | ... | @@ -17691,11 +17695,18 @@ ul.sf_date_field .sf-datepicker { |
| 17691 | color: #fff; | 17695 | color: #fff; |
| 17692 | margin-left: -50%; | 17696 | margin-left: -50%; |
| 17693 | margin-right: -50%; | 17697 | margin-right: -50%; |
| 17698 | margin-bottom: -25px; | ||
| 17699 | margin-top: 25px; | ||
| 17694 | padding-left: 50%; | 17700 | padding-left: 50%; |
| 17695 | padding-right: 50%; | 17701 | padding-right: 50%; |
| 17702 | background-color: #000; | ||
| 17696 | box-shadow: inset 0 0 0 2000px rgba(0, 0, 0, 0.3); | 17703 | box-shadow: inset 0 0 0 2000px rgba(0, 0, 0, 0.3); |
| 17697 | } | 17704 | } |
| 17698 | 17705 | ||
| 17706 | .side-menu-page .call-out-block { | ||
| 17707 | margin-left: -75%; | ||
| 17708 | } | ||
| 17709 | |||
| 17699 | .call-out-block h2, .call-out-block .h2 { | 17710 | .call-out-block h2, .call-out-block .h2 { |
| 17700 | text-align: center; | 17711 | text-align: center; |
| 17701 | } | 17712 | } |
| ... | @@ -17718,6 +17729,7 @@ ul.sf_date_field .sf-datepicker { | ... | @@ -17718,6 +17729,7 @@ ul.sf_date_field .sf-datepicker { |
| 17718 | text-transform: uppercase; | 17729 | text-transform: uppercase; |
| 17719 | display: inline-block; | 17730 | display: inline-block; |
| 17720 | width: unset; | 17731 | width: unset; |
| 17732 | border-radius: 40px !important; | ||
| 17721 | } | 17733 | } |
| 17722 | 17734 | ||
| 17723 | .call-out-block a:hover { | 17735 | .call-out-block a:hover { | ... | ... |
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
| ... | @@ -7,133 +7,33 @@ | ... | @@ -7,133 +7,33 @@ |
| 7 | 7 | ||
| 8 | 8 | ||
| 9 | function get_breadcrumb() { | 9 | function get_breadcrumb() { |
| 10 | if ( function_exists( 'yoast_breadcrumb' ) ) { | 10 | global $post; |
| 11 | ob_start(); | 11 | echo '<a href="'.home_url().'" rel="nofollow">Home</a>'; |
| 12 | yoast_breadcrumb( '<p id="breadcrumb" class="meta-info">', '</p>' ); | 12 | echo '<span> / </span>'; |
| 13 | $breadcrumb = trim( ob_get_clean() ); | 13 | if (is_category() || is_single()) { |
| 14 | 14 | the_category(' / '); | |
| 15 | // if ( is_singular() ) | 15 | if (is_single()) { |
| 16 | // $breadcrumb = trim( preg_replace( '/ ' . WPSEO_Options::get( 'breadcrumbs-sep' ) . ' <span class="breadcrumb_last" aria-current="page">(.*)<\/span>/i', '', | 16 | echo '<span> / </span>'; |
| 17 | // $breadcrumb ) ); | 17 | the_title(); |
| 18 | 18 | } | |
| 19 | 19 | } elseif (is_page()) { | |
| 20 | 20 | if($post->post_parent){ | |
| 21 | $main_nav_items = wp_get_nav_menu_items('Main Menu'); | 21 | $anc = get_post_ancestors( $post->ID ); |
| 22 | $post_id = get_the_ID(); | 22 | $title = get_the_title(); |
| 23 | 23 | foreach ( $anc as $ancestor ) { | |
| 24 | $parents = []; | 24 | $output = '<a href="'.get_permalink($ancestor).'" title="'.get_the_title($ancestor).'">'.get_the_title($ancestor).'</a> <span> / </span>'; |
| 25 | $my_parent = null; | 25 | } |
| 26 | 26 | echo $output; | |
| 27 | foreach($main_nav_items as $ni) { | 27 | echo '<strong title="'.$title.'"> '.$title.'</strong>'; |
| 28 | if($ni->menu_item_parent == '0') { | ||
| 29 | $parents[$ni->ID] = $ni; | ||
| 30 | } | ||
| 31 | if($ni->object_id == $post_id) { | ||
| 32 | $my_parent = $ni->menu_item_parent; | ||
| 33 | } | ||
| 34 | $parent_postID = wp_get_post_parent_id($post_id); | ||
| 35 | if($ni->object_id == $parent_postID) { | ||
| 36 | $my_parent = $ni->menu_item_parent; | ||
| 37 | } | ||
| 38 | } | ||
| 39 | |||
| 40 | |||
| 41 | $bread = explode(' | ', $breadcrumb); | ||
| 42 | |||
| 43 | array_pop($bread); | ||
| 44 | |||
| 45 | // $new_bread[] = $bread[0]; | ||
| 46 | |||
| 47 | // var_dump($bread[0]);exit; | ||
| 48 | |||
| 49 | $categories = get_the_terms(null, 'category'); | ||
| 50 | |||
| 51 | if(is_array($categories)) { | ||
| 52 | foreach($categories as $cat) { | ||
| 53 | $parents_from_cat = get_field('parent_pages', $cat); | ||
| 54 | if($parents_from_cat) { | ||
| 55 | break; | ||
| 56 | } | ||
| 57 | } | ||
| 58 | } | ||
| 59 | |||
| 60 | if(get_locale() == 'fr_FR') { | ||
| 61 | $new_bread[] = "<p id='breadcrumb' class='meta-info'><span><span><a href='/'>Accueil</a></span>"; | ||
| 62 | } else { | ||
| 63 | $new_bread[] = "<p id='breadcrumb' class='meta-info'><span><span><a href='/'>Home</a></span></span>"; | ||
| 64 | } | ||
| 65 | |||
| 66 | if($parents_from_cat) { | ||
| 67 | |||
| 68 | foreach($parents_from_cat as $pcat) { | ||
| 69 | |||
| 70 | $parent_post = url_to_postid($pcat); | ||
| 71 | if($parent_post) { | ||
| 72 | $parent_post = get_post($parent_post); | ||
| 73 | $pcat_ansests = get_post_ancestors($parent_post); | ||
| 74 | if(is_array($pcat_ansests)) { | ||
| 75 | $pcat_ansests = array_reverse($pcat_ansests); | ||
| 76 | foreach($pcat_ansests as $ansestor) { | ||
| 77 | $ansestor_post = get_post($ansestor); | ||
| 78 | if($ansestor_post) { | ||
| 79 | $new_bread[] = "<span><a href='".get_permalink($ansestor)."'>".$ansestor_post->post_title."</a></span>"; | ||
| 80 | } | ||
| 81 | } | ||
| 82 | } | ||
| 83 | $new_bread[] = "<span><a href='".get_permalink($parent_post->ID)."'>".$parent_post->post_title."</a></span>"; | ||
| 84 | } | ||
| 85 | |||
| 86 | } | ||
| 87 | |||
| 88 | } else { | ||
| 89 | |||
| 90 | if(is_single()) { | ||
| 91 | |||
| 92 | $parent_post = get_field('latest_news_and_stories_page', 'option'); | ||
| 93 | |||
| 94 | if($parent_post) { | ||
| 95 | |||
| 96 | // $parent_post = url_to_postid($parent_post); | ||
| 97 | |||
| 98 | // if($parent_post) { | ||
| 99 | |||
| 100 | $parent_post = get_post($parent_post); | ||
| 101 | |||
| 102 | if($parent_post) { | ||
| 103 | |||
| 104 | $new_bread[] = "<span><a href='".get_permalink($parent_post->ID)."'>".$parent_post->post_title."</a></span>"; | ||
| 105 | |||
| 106 | } | ||
| 107 | // } | ||
| 108 | } | ||
| 109 | |||
| 110 | } else { | 28 | } else { |
| 111 | 29 | echo '<strong> '.get_the_title().'</strong>'; | |
| 112 | if(isset($parents[$my_parent])) { | ||
| 113 | $new_bread[] = "<span>".$parents[$my_parent]->post_title."</span>"; | ||
| 114 | } | 30 | } |
| 115 | |||
| 116 | |||
| 117 | if(isset($bread[1])) { | ||
| 118 | $new_bread[] = $bread[1]; | ||
| 119 | } | ||
| 120 | |||
| 121 | if(isset($bread[2])) { | ||
| 122 | $new_bread[] = $bread[2]; | ||
| 123 | } | ||
| 124 | |||
| 125 | } | ||
| 126 | |||
| 127 | |||
| 128 | } | ||
| 129 | |||
| 130 | $breadcrumb = implode(' | ', $new_bread); | ||
| 131 | |||
| 132 | echo $breadcrumb; | ||
| 133 | |||
| 134 | ?> | ||
| 135 | |||
| 136 | |||
| 137 | <?php | ||
| 138 | } | 31 | } |
| 32 | elseif (is_tag()) {single_tag_title();} | ||
| 33 | elseif (is_day()) {echo"Archive for "; the_time('F jS, Y');} | ||
| 34 | elseif (is_month()) {echo"Archive for "; the_time('F, Y');} | ||
| 35 | elseif (is_year()) {echo"Archive for "; the_time('Y');} | ||
| 36 | elseif (is_author()) {echo"Author Archive";} | ||
| 37 | elseif (isset($_GET['paged']) && !empty($_GET['paged'])) {echo "Blog Archives";} | ||
| 38 | elseif (is_search()) {echo"Search Results";} | ||
| 139 | } | 39 | } |
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
| ... | @@ -43,7 +43,7 @@ if ($thumbnail_image && isset($thumbnail_image[0])) { | ... | @@ -43,7 +43,7 @@ if ($thumbnail_image && isset($thumbnail_image[0])) { |
| 43 | </div> | 43 | </div> |
| 44 | </header><!-- .entry-header --> | 44 | </header><!-- .entry-header --> |
| 45 | <?php } ?> | 45 | <?php } ?> |
| 46 | <div class="wrapper" id="page-wrapper"> | 46 | <div class="wrapper full-width" id="page-wrapper"> |
| 47 | 47 | ||
| 48 | <div class="<?php echo esc_attr( $container ); ?>" id="content" tabindex="-1"> | 48 | <div class="<?php echo esc_attr( $container ); ?>" id="content" tabindex="-1"> |
| 49 | 49 | ... | ... |
| ... | @@ -47,7 +47,7 @@ if ($thumbnail_image && isset($thumbnail_image[0])) { | ... | @@ -47,7 +47,7 @@ if ($thumbnail_image && isset($thumbnail_image[0])) { |
| 47 | </div> | 47 | </div> |
| 48 | </header><!-- .entry-header --> | 48 | </header><!-- .entry-header --> |
| 49 | <?php } ?> | 49 | <?php } ?> |
| 50 | <div class="wrapper" id="page-wrapper"> | 50 | <div class="wrapper side-menu-page" id="page-wrapper"> |
| 51 | 51 | ||
| 52 | <div class="<?php echo esc_attr( $container ); ?>" id="content" tabindex="-1"> | 52 | <div class="<?php echo esc_attr( $container ); ?>" id="content" tabindex="-1"> |
| 53 | <div class="col-sm-12 col-md-12 col-lg-3 widget-area" id="page-sidebar"> | 53 | <div class="col-sm-12 col-md-12 col-lg-3 widget-area" id="page-sidebar"> | ... | ... |
| ... | @@ -10,11 +10,20 @@ | ... | @@ -10,11 +10,20 @@ |
| 10 | color:#fff; | 10 | color:#fff; |
| 11 | margin-left:-50%; | 11 | margin-left:-50%; |
| 12 | margin-right:-50%; | 12 | margin-right:-50%; |
| 13 | margin-bottom: -25px; | ||
| 14 | margin-top: 25px; | ||
| 13 | padding-left:50%; | 15 | padding-left:50%; |
| 14 | padding-right:50%; | 16 | padding-right:50%; |
| 17 | background-color: #000; | ||
| 15 | box-shadow: inset 0 0 0 2000px rgba(0, 0, 0, 0.3); | 18 | box-shadow: inset 0 0 0 2000px rgba(0, 0, 0, 0.3); |
| 16 | } | 19 | } |
| 17 | 20 | ||
| 21 | .side-menu-page{ | ||
| 22 | .call-out-block{ | ||
| 23 | margin-left:-75%; | ||
| 24 | } | ||
| 25 | } | ||
| 26 | |||
| 18 | .call-out-block h2{ | 27 | .call-out-block h2{ |
| 19 | text-align: center; | 28 | text-align: center; |
| 20 | } | 29 | } |
| ... | @@ -35,7 +44,7 @@ | ... | @@ -35,7 +44,7 @@ |
| 35 | text-transform: uppercase; | 44 | text-transform: uppercase; |
| 36 | display: inline-block; | 45 | display: inline-block; |
| 37 | width: unset; | 46 | width: unset; |
| 38 | 47 | border-radius: 40px !important; | |
| 39 | } | 48 | } |
| 40 | 49 | ||
| 41 | .call-out-block a:hover{ | 50 | .call-out-block a:hover{ | ... | ... |
| ... | @@ -174,10 +174,15 @@ | ... | @@ -174,10 +174,15 @@ |
| 174 | margin-top: 34px; | 174 | margin-top: 34px; |
| 175 | margin: 34px 40px 0 40px; | 175 | margin: 34px 40px 0 40px; |
| 176 | .breadcrumb{ | 176 | .breadcrumb{ |
| 177 | margin-bottom: 0px; | 177 | a{ |
| 178 | #breadcrumb{ | 178 | text-decoration: none; |
| 179 | margin-bottom: 10px; | 179 | text-transform: capitalize; |
| 180 | } | 180 | } |
| 181 | span{ | ||
| 182 | margin: 0px 10px; | ||
| 183 | } | ||
| 184 | margin-bottom: 0px; | ||
| 185 | |||
| 181 | } | 186 | } |
| 182 | h1{ | 187 | h1{ |
| 183 | font-size: 45px; | 188 | font-size: 45px; | ... | ... |
-
Please register or sign in to post a comment