Changeset 1875668
- Timestamp:
- 05/16/2018 03:42:48 PM (8 years ago)
- Location:
- socius-marketing-page-taxonomy/trunk
- Files:
-
- 7 edited
-
css/styles.css (modified) (1 diff)
-
css/styles.min.css (modified) (1 diff)
-
inc/archive-pages.php (modified) (2 diffs)
-
inc/options-page.php (modified) (1 diff)
-
inc/template-archive.php (modified) (3 diffs)
-
readme.txt (modified) (2 diffs)
-
socius-marketing-page-taxonomy.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
socius-marketing-page-taxonomy/trunk/css/styles.css
r1756170 r1875668 106 106 text-align:center; 107 107 margin-bottom:20px; 108 } 109 .smct-category.smct-list { 110 text-align:left; 111 } 112 .smct-category.smct-list .smct-image-wrap { 113 display: none; 108 114 } 109 115 .smct-category img, -
socius-marketing-page-taxonomy/trunk/css/styles.min.css
r1756170 r1875668 1 .stateface,.worldface{ font-size:150px;line-height:1;text-transform:none!important;text-align:center;display:block}.smct-category,.smct-state,.stateface,.worldface{text-align:center}@font-face{font-family:worldface;src:url(fonts/worldface.eot?cvdz4z);src:url(fonts/worldface.eot?cvdz4z#iefix) format('embedded-opentype'),url(fonts/worldface.ttf?cvdz4z) format('truetype'),url(fonts/worldface.woff?cvdz4z) format('woff'),url(fonts/worldface.svg?cvdz4z#worldface) format('svg');font-weight:400;font-style:normal}.worldface{font-family:worldface}.icon-globe:before{content:"\e90a"}.icon-asia:before{content:"\e908"}.icon-africa:before{content:"\e909"}.icon-australia:before{content:"\e907"}.icon-caribbean:before{content:"\e903"}.icon-canada:before{content:"\e906"}.icon-central-america:before{content:"\e904"}.icon-europe:before{content:"\e901"}.icon-mexico:before{content:"\e905"}.icon-middle-east:before{content:"\e900"}.icon-south-america:before{content:"\e902"}@font-face{font-family:stateface;src:url(fonts/stateface-regular-webfont.eot);src:url(fonts/stateface-regular-webfont.eot?#iefix) format('embedded-opentype'),url(fonts/stateface-regular-webfont.woff) format('woff'),url(fonts/stateface-regular-webfont.ttf) format('truetype'),url(fonts/stateface-regular-webfont.svg#statefaceregular) format('svg');font-weight:400;font-style:normal}.stateface{font-family:stateface}#smct-cities-listing a,.smct-archive-title a,.smct-category a,.smct-page-title{text-transform:capitalize}.stateface.cities{font-size:200px}.smct-state a,.smct-state a:active,.smct-state a:focus,.smct-state a:hover{text-decoration:none!important;text-transform:capitalize}#smct-cities-listing ul{list-style-type:none;padding-left:0}.smct-archive-title{margin-top:0}.smct-category{margin-bottom:20px}#smct_content .smct-category img,.smct-category img{margin:0 auto 5px;display:block;width:100%\9;max-width:100%;height:auto}.smct-category h3{margin:0 auto}.smct-category a{text-decoration:none}.smct-archive-summary{margin-bottom:20px}.smct-image-wrap{display:block;background-repeat:no-repeat;background-position:center center;background-size:cover;width:100%;padding-bottom:60%;margin-bottom:10px;opacity:1;transition:all .25s ease-in-out;-moz-transition:all .25s ease-in-out;-webkit-transition:all .25s ease-in-out}.smct-archive-summary a:hover .smct-image-wrap,.smct-category a:hover .smct-image-wrap{opacity:.75}#smct_content .smct-image img,.smct-image img{display:block;margin:0 auto;width:100%\9;max-width:100%;height:auto}#smct-nav-above{margin-bottom:10px}.smct-row{margin-right:-15px;margin-left:-15px}.smct-row:after,.smct-row:before{display:table;content:''}.smct-row:after{clear:both}:after,:before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.smct-col-md-3,.smct-col-md-4,.smct-col-md-9,.smct-col-sm-3,.smct-col-sm-4,.smct-col-sm-6,.smct-col-sm-8{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.smct-col-xs-12{width:100%}@media (min-width:768px){.smct-col-md-3,.smct-col-md-4,.smct-col-md-9,.smct-col-sm-3,.smct-col-sm-4,.smct-col-sm-6,.smct-col-sm-8{float:left}.smct-col-sm-3{width:25%}.smct-col-sm-4{width:33.33333333%}.smct-col-sm-6{width:50%}.smct-col-sm-8{width:66.66666667%}.smct-category{display:inline-block;float:none!important;vertical-align:top}}@media (min-width:992px){.smct-col-md-3{width:25%}.smct-col-md-4{width:33.33333333%}.smct-col-md-9{width:75%}}1 .stateface,.worldface{display:block;font-size:150px;line-height:1;text-transform:none!important;text-align:center}.smct-category,.smct-state,.stateface,.worldface{text-align:center}@font-face{font-family:worldface;src:url(fonts/worldface.eot?cvdz4z);src:url(fonts/worldface.eot?cvdz4z#iefix) format('embedded-opentype'),url(fonts/worldface.ttf?cvdz4z) format('truetype'),url(fonts/worldface.woff?cvdz4z) format('woff'),url(fonts/worldface.svg?cvdz4z#worldface) format('svg');font-weight:400;font-style:normal}.worldface{font-family:worldface}.icon-globe:before{content:"\e90a"}.icon-asia:before{content:"\e908"}.icon-africa:before{content:"\e909"}.icon-australia:before{content:"\e907"}.icon-caribbean:before{content:"\e903"}.icon-canada:before{content:"\e906"}.icon-central-america:before{content:"\e904"}.icon-europe:before{content:"\e901"}.icon-mexico:before{content:"\e905"}.icon-middle-east:before{content:"\e900"}.icon-south-america:before{content:"\e902"}@font-face{font-family:stateface;src:url(fonts/stateface-regular-webfont.eot);src:url(fonts/stateface-regular-webfont.eot?#iefix) format('embedded-opentype'),url(fonts/stateface-regular-webfont.woff) format('woff'),url(fonts/stateface-regular-webfont.ttf) format('truetype'),url(fonts/stateface-regular-webfont.svg#statefaceregular) format('svg');font-weight:400;font-style:normal}.stateface{font-family:stateface}#smct-cities-listing a,.smct-archive-title a,.smct-category a,.smct-page-title{text-transform:capitalize}.stateface.cities{font-size:200px}.smct-state a,.smct-state a:active,.smct-state a:focus,.smct-state a:hover{text-decoration:none!important;text-transform:capitalize}#smct-cities-listing ul{list-style-type:none;padding-left:0}.smct-archive-title{margin-top:0}.smct-category{margin-bottom:20px}.smct-category.smct-list{text-align:left}.smct-category.smct-list .smct-image-wrap{display:none}#smct_content .smct-category img,.smct-category img{margin:0 auto 5px;display:block;width:100%\9;max-width:100%;height:auto}.smct-category h3{margin:0 auto}.smct-category a{text-decoration:none}.smct-archive-summary{margin-bottom:20px}.smct-image-wrap{display:block;background-repeat:no-repeat;background-position:center center;background-size:cover;width:100%;padding-bottom:60%;margin-bottom:10px;opacity:1;transition:all .25s ease-in-out;-moz-transition:all .25s ease-in-out;-webkit-transition:all .25s ease-in-out}.smct-archive-summary a:hover .smct-image-wrap,.smct-category a:hover .smct-image-wrap{opacity:.75}#smct_content .smct-image img,.smct-image img{display:block;margin:0 auto;width:100%\9;max-width:100%;height:auto}#smct-nav-above{margin-bottom:10px}.smct-row{margin-right:-15px;margin-left:-15px}.smct-row:after,.smct-row:before{display:table;content:''}.smct-row:after{clear:both}:after,:before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.smct-col-md-3,.smct-col-md-4,.smct-col-md-9,.smct-col-sm-3,.smct-col-sm-4,.smct-col-sm-6,.smct-col-sm-8{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.smct-col-xs-12{width:100%}@media (min-width:768px){.smct-col-md-3,.smct-col-md-4,.smct-col-md-9,.smct-col-sm-3,.smct-col-sm-4,.smct-col-sm-6,.smct-col-sm-8{float:left}.smct-col-sm-3{width:25%}.smct-col-sm-4{width:33.33333333%}.smct-col-sm-6{width:50%}.smct-col-sm-8{width:66.66666667%}.smct-category{display:inline-block;float:none!important;vertical-align:top}}@media (min-width:992px){.smct-col-md-3{width:25%}.smct-col-md-4{width:33.33333333%}.smct-col-md-9{width:75%}} -
socius-marketing-page-taxonomy/trunk/inc/archive-pages.php
r1756170 r1875668 72 72 while ($the_query->have_posts() ) { 73 73 $the_query->the_post(); 74 if( smct_grab_first_image_for_categories() ) {75 if($i < 1 ) {76 $first_image = smct_grab_first_image_for_categories();77 if (strpos($first_image, 'default') !== false) {78 $cat_content = category_description($term->term_id);79 $output = preg_match_all('/<img.+src=[\'"]([^\'"]+)[\'"].*>/i', $cat_content, $matches);80 if (isset($matches[1][0])) { $first_image = $matches[1][0]; }81 } else {82 //use default image83 }74 if( smct_grab_first_image_for_categories() ) { 75 if($i < 1 ) { 76 $first_image = smct_grab_first_image_for_categories(); 77 if (strpos($first_image, 'default') !== false) { 78 $cat_content = category_description($term->term_id); 79 $output = preg_match_all('/<img.+src=[\'"]([^\'"]+)[\'"].*>/i', $cat_content, $matches); 80 if (isset($matches[1][0])) { $first_image = $matches[1][0]; } 81 } else { 82 //use default image 83 } 84 84 $i++; 85 85 } … … 90 90 91 91 $smct_number_of_columns = get_option('smct_number_of_columns'); 92 if($smct_number_of_columns[0] == '3wide') { 92 $display_images = get_option('smct_category_display_layout'); 93 if($display_images[0] == 'no') { 94 $width = 'smct-col-xs-12 smct-category smct-list'; 95 } elseif($smct_number_of_columns[0] == '3wide') { 93 96 $width = 'smct-col-md-4 smct-col-sm-6 smct-category'; 94 97 } else { 95 98 $width = 'smct-col-md-3 smct-col-sm-6 smct-category'; 96 99 } 100 97 101 $content .= '<div id="smct-' . $term->slug . '" class="'. $width .'">'; 98 102 $content .= '<h3><a href="' . esc_url( get_term_link( $term ) ) . '"><span class="smct-image-wrap" style="background-image:url(' . $first_image . ')"></span>' . $term->name . '</a></h3>'; -
socius-marketing-page-taxonomy/trunk/inc/options-page.php
r1756170 r1875668 81 81 'uid' => 'smct_display_page_titles', 82 82 'label' => 'Display Page Titles in the Content?', 83 'section' => 'smct_section_two', 84 'type' => 'radio', 85 'options' => array( 86 'yes' => 'Yes', 87 'no' => 'No', 88 ), 89 'default' => array('yes'), 90 ), 91 array( 92 'uid' => 'smct_category_display_layout', 93 'label' => 'Display Images in Category Archive?', 83 94 'section' => 'smct_section_two', 84 95 'type' => 'radio', -
socius-marketing-page-taxonomy/trunk/inc/template-archive.php
r1875495 r1875668 144 144 145 145 <?php 146 $display_images = get_option('smct_category_display_layout'); 146 147 $row_width = 'smct-row'; 147 148 $left_col_widths = 'smct-col-md-3 smct-col-sm-4 smct-col-xs-12 smct-image'; 148 149 $right_col_widths = 'smct-col-md-9 smct-col-sm-8 smct-col-xs-12 smct-text'; 149 150 $photo = smct_grab_first_image(); 150 if(empty($photo) ) {151 if(empty($photo) || $display_images[0] == 'no') { 151 152 $row_width = ''; 152 153 $left_col_widths = 'hidden-xs hidden-sm hidden-md hidden-lg'; 153 154 $right_col_widths = 'smct-col-xs-12 smct-text'; 154 } ?> 155 } 156 ?> 155 157 <div class="smct-archive-summary <?php echo $row_width; ?>"> 158 <?php if(!empty($photo) && $display_images[0] !== 'no') { ?> 156 159 <div class="<?php echo $left_col_widths;?>"> 157 160 <a href="<?php the_permalink(); ?>"><span class="smct-image-wrap" style="background-image:url(<?php echo smct_grab_first_image(); ?>)"></span></a> 158 161 </div> 162 <?php } ?> 159 163 <div class="<?php echo $right_col_widths;?>"> 160 164 <h3 class="smct-archive-title"><a href="<?php the_permalink(); ?>" title="<?php printf( the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"> 161 165 <?php //Use Custom Page Title meta, if there is one 162 if(get_option('smct_alternate_page_title') !== '') {166 if(get_option('smct_alternate_page_title') !== false) { 163 167 if( class_exists('acf') ) { 164 168 if(get_field(get_option('smct_alternate_page_title'))) { 165 169 the_field(get_option('smct_alternate_page_title')); 166 170 } elseif (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h1>'), $matches)) { 167 if( !empty($matches)) {171 if(empty($matches)) { 168 172 if (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h3>'), $matches)) { 169 173 echo strip_tags($matches[0][0]); … … 176 180 } 177 181 } elseif (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h1>'), $matches)) { 178 if( !empty($matches)) {182 if(empty($matches)) { 179 183 if (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h3>'), $matches)) { 180 184 echo strip_tags($matches[0][0]); … … 188 192 //Check for H1 first; use H3 as a fallback 189 193 } elseif (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h1>'), $matches)) { 190 if( !empty($matches)) {194 if(empty($matches)) { 191 195 if (preg_match_all('#(<h[0-6].*?>).*?(</h[0-6]>)#', strip_tags(get_the_content(),'<h3>'), $matches)) { 192 196 echo strip_tags($matches[0][0]); -
socius-marketing-page-taxonomy/trunk/readme.txt
r1875495 r1875668 4 4 Requires at least: 3.0.1 5 5 Tested up to: 4.9 6 Stable tag: 1.1. 26 Stable tag: 1.1.3 7 7 License: GPLv2 or later 8 8 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 61 61 62 62 == Changelog == 63 = 1.1.3 = 64 * Added option to hide thumbnails on category archive 65 63 66 = 1.1.2 = 64 67 * Edited query for archive page title to only pull H3 if there is no H1 -
socius-marketing-page-taxonomy/trunk/socius-marketing-page-taxonomy.php
r1875495 r1875668 4 4 * Plugin URI: http://sociusmarketing.com 5 5 * Description: Adds custom taxonomies for product categories and areas served. Be sure to update your permalinks after activation. 6 * Version: 1.1. 26 * Version: 1.1.3 7 7 * Author: Socius Marketing 8 8 * Author URI: http://sociusmarketing.com
Note: See TracChangeset
for help on using the changeset viewer.