@@ -60,12 +60,12 @@ |
||
| 60 | 60 | <strong><?php _e( 'Get your Tourism Establishment Online', 'lsx' ); ?></strong> |
| 61 | 61 | |
| 62 | 62 | <?php |
| 63 | - if(is_singular('landing-page')){ |
|
| 64 | - $email_address = get_post_meta(get_the_ID(),'email_address',true); |
|
| 65 | - if(false === $email_address){ |
|
| 63 | + if(is_singular('landing-page')){ |
|
| 64 | + $email_address = get_post_meta(get_the_ID(),'email_address',true); |
|
| 65 | + if(false === $email_address){ |
|
| 66 | 66 | $email_address = '[email protected]'; |
| 67 | 67 | } |
| 68 | - } ?> |
|
| 68 | + } ?> |
|
| 69 | 69 | |
| 70 | 70 | <span class="email-address"><?php _e( 'Questions? Email Us: ', 'lsx' ); ?><a href="mailto:<?php echo $email_address; ?>"><?php echo $email_address; ?></a></span> |
| 71 | 71 | </div> |
@@ -159,17 +159,17 @@ |
||
| 159 | 159 | * @return null Null on failure with no changes to parameters. |
| 160 | 160 | */ |
| 161 | 161 | public function display_element( $element, &$children_elements, $max_depth, $depth, $args, &$output ) { |
| 162 | - if ( ! $element ) |
|
| 163 | - return; |
|
| 162 | + if ( ! $element ) |
|
| 163 | + return; |
|
| 164 | 164 | |
| 165 | - $id_field = $this->db_fields['id']; |
|
| 165 | + $id_field = $this->db_fields['id']; |
|
| 166 | 166 | |
| 167 | - // Display this element. |
|
| 168 | - if ( is_object( $args[0] ) ) |
|
| 169 | - $args[0]->has_children = ! empty( $children_elements[ $element->$id_field ] ); |
|
| 167 | + // Display this element. |
|
| 168 | + if ( is_object( $args[0] ) ) |
|
| 169 | + $args[0]->has_children = ! empty( $children_elements[ $element->$id_field ] ); |
|
| 170 | 170 | |
| 171 | - parent::display_element( $element, $children_elements, $max_depth, $depth, $args, $output ); |
|
| 172 | - } |
|
| 171 | + parent::display_element( $element, $children_elements, $max_depth, $depth, $args, $output ); |
|
| 172 | + } |
|
| 173 | 173 | |
| 174 | 174 | /** |
| 175 | 175 | * Menu Fallback |
@@ -123,11 +123,11 @@ discard block |
||
| 123 | 123 | * @category portfolio |
| 124 | 124 | */ |
| 125 | 125 | function lsx_remove_single_related_posts() { |
| 126 | - if ( is_single() && class_exists( 'Jetpack_RelatedPosts' ) ) { |
|
| 127 | - $jprp = Jetpack_RelatedPosts::init(); |
|
| 128 | - $callback = array( $jprp, 'filter_add_target_to_dom' ); |
|
| 129 | - remove_filter( 'the_content', $callback, 40 ); |
|
| 130 | - } |
|
| 126 | + if ( is_single() && class_exists( 'Jetpack_RelatedPosts' ) ) { |
|
| 127 | + $jprp = Jetpack_RelatedPosts::init(); |
|
| 128 | + $callback = array( $jprp, 'filter_add_target_to_dom' ); |
|
| 129 | + remove_filter( 'the_content', $callback, 40 ); |
|
| 130 | + } |
|
| 131 | 131 | } |
| 132 | 132 | add_filter( 'wp', 'lsx_remove_single_related_posts', 20 ); |
| 133 | 133 | |
@@ -311,7 +311,7 @@ discard block |
||
| 311 | 311 | if(is_array($types)){ |
| 312 | 312 | foreach ($types as $type) { |
| 313 | 313 | $content = '<li><a href="#" data-filter=".'.$type->slug.'">'; |
| 314 | - $content .= $type->name; |
|
| 314 | + $content .= $type->name; |
|
| 315 | 315 | $content .= '</a></li>'; |
| 316 | 316 | echo $content; |
| 317 | 317 | echo "\n"; |
@@ -125,7 +125,7 @@ discard block |
||
| 125 | 125 | * @category styles |
| 126 | 126 | */ |
| 127 | 127 | function lsx_sensei_styles() { |
| 128 | - wp_enqueue_style( 'sensei', get_template_directory_uri() . '/css/sensei.css' ); |
|
| 128 | + wp_enqueue_style( 'sensei', get_template_directory_uri() . '/css/sensei.css' ); |
|
| 129 | 129 | } |
| 130 | 130 | add_action( 'wp_enqueue_scripts', 'lsx_sensei_styles' ); |
| 131 | 131 | |
@@ -136,10 +136,10 @@ discard block |
||
| 136 | 136 | * @category styles |
| 137 | 137 | */ |
| 138 | 138 | function lsx_sensei_redirect_to_home( $query ){ |
| 139 | - if(!is_admin() && is_post_type_archive( 'lesson' ) ) { |
|
| 140 | - wp_redirect( home_url() . '/courses-overview' ); |
|
| 141 | - exit; |
|
| 142 | - } |
|
| 139 | + if(!is_admin() && is_post_type_archive( 'lesson' ) ) { |
|
| 140 | + wp_redirect( home_url() . '/courses-overview' ); |
|
| 141 | + exit; |
|
| 142 | + } |
|
| 143 | 143 | } |
| 144 | 144 | add_action( 'parse_query', 'lsx_sensei_redirect_to_home' ); |
| 145 | 145 | |
@@ -12,7 +12,7 @@ discard block |
||
| 12 | 12 | |
| 13 | 13 | /** |
| 14 | 14 | * Constructor |
| 15 | - **/ |
|
| 15 | + **/ |
|
| 16 | 16 | public function __construct($title, $location, $cssDeclaration, $cssClass) |
| 17 | 17 | { |
| 18 | 18 | $this->title = $title; |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | /** |
| 25 | 25 | * Getters |
| 26 | 26 | * taken from: http://stackoverflow.com/questions/4478661/getter-and-setter |
| 27 | - **/ |
|
| 27 | + **/ |
|
| 28 | 28 | public function __get($property) |
| 29 | 29 | { |
| 30 | 30 | if (property_exists($this, $property)) { |
@@ -14,27 +14,27 @@ discard block |
||
| 14 | 14 | */ |
| 15 | 15 | class LSX_Walker_Comment extends Walker_Comment { |
| 16 | 16 | function start_lvl(&$output, $depth = 0, $args = array()) { |
| 17 | - $GLOBALS['comment_depth'] = $depth + 1; ?> |
|
| 17 | + $GLOBALS['comment_depth'] = $depth + 1; ?> |
|
| 18 | 18 | <ul <?php comment_class('media unstyled comment-' . get_comment_ID()); ?>> |
| 19 | 19 | <?php |
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | function end_lvl(&$output, $depth = 0, $args = array()) { |
| 23 | - $GLOBALS['comment_depth'] = $depth + 1; |
|
| 24 | - echo '</ul>'; |
|
| 23 | + $GLOBALS['comment_depth'] = $depth + 1; |
|
| 24 | + echo '</ul>'; |
|
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | function start_el(&$output, $comment, $depth = 0, $args = array(), $id = 0) { |
| 28 | - $depth++; |
|
| 29 | - $GLOBALS['comment_depth'] = $depth; |
|
| 30 | - $GLOBALS['comment'] = $comment; |
|
| 28 | + $depth++; |
|
| 29 | + $GLOBALS['comment_depth'] = $depth; |
|
| 30 | + $GLOBALS['comment'] = $comment; |
|
| 31 | 31 | |
| 32 | - if (!empty($args['callback'])) { |
|
| 33 | - call_user_func($args['callback'], $comment, $args, $depth); |
|
| 34 | - return; |
|
| 35 | - } |
|
| 32 | + if (!empty($args['callback'])) { |
|
| 33 | + call_user_func($args['callback'], $comment, $args, $depth); |
|
| 34 | + return; |
|
| 35 | + } |
|
| 36 | 36 | |
| 37 | - extract($args, EXTR_SKIP);?> |
|
| 37 | + extract($args, EXTR_SKIP);?> |
|
| 38 | 38 | |
| 39 | 39 | <li id="comment-<?php comment_ID(); ?>" <?php comment_class('media comment-' . get_comment_ID()); ?>> |
| 40 | 40 | <?php get_template_part('comment'); ?> |
@@ -42,11 +42,11 @@ discard block |
||
| 42 | 42 | } |
| 43 | 43 | |
| 44 | 44 | function end_el(&$output, $comment, $depth = 0, $args = array()) { |
| 45 | - if (!empty($args['end-callback'])) { |
|
| 46 | - call_user_func($args['end-callback'], $comment, $args, $depth); |
|
| 47 | - return; |
|
| 48 | - } |
|
| 49 | - echo "</div></li>\n"; |
|
| 45 | + if (!empty($args['end-callback'])) { |
|
| 46 | + call_user_func($args['end-callback'], $comment, $args, $depth); |
|
| 47 | + return; |
|
| 48 | + } |
|
| 49 | + echo "</div></li>\n"; |
|
| 50 | 50 | } |
| 51 | 51 | |
| 52 | 52 | } |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | */ |
| 12 | 12 | function lsx_breadcrumbs() { |
| 13 | 13 | if (!function_exists('yoast_breadcrumb') && !function_exists('woocommerce_breadcrumb')) { |
| 14 | - return null; |
|
| 14 | + return null; |
|
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | $show_on_front = get_option('show_on_front'); |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | * Displays logo when applicable |
| 69 | 69 | * |
| 70 | 70 | * @return void |
| 71 | - */ |
|
| 71 | + */ |
|
| 72 | 72 | function lsx_site_title() { |
| 73 | 73 | ?> |
| 74 | 74 | <div class="site-branding"> |
@@ -117,13 +117,13 @@ discard block |
||
| 117 | 117 | |
| 118 | 118 | |
| 119 | 119 | <?php |
| 120 | - $post_categories = wp_get_post_categories( get_the_ID() ); |
|
| 121 | - $cats = array(); |
|
| 122 | - foreach($post_categories as $c){ |
|
| 123 | - $cat = get_category( $c ); |
|
| 124 | - $cats[] = '<a href="' . get_category_link( $cat->term_id ) . '" title="' . sprintf( __( "View all posts in %s" , 'lsx' ), $cat->name ) . '" ' . '>' . $cat->name.'</a>'; |
|
| 125 | - } |
|
| 126 | - if(!empty($cats)){ ?> |
|
| 120 | + $post_categories = wp_get_post_categories( get_the_ID() ); |
|
| 121 | + $cats = array(); |
|
| 122 | + foreach($post_categories as $c){ |
|
| 123 | + $cat = get_category( $c ); |
|
| 124 | + $cats[] = '<a href="' . get_category_link( $cat->term_id ) . '" title="' . sprintf( __( "View all posts in %s" , 'lsx' ), $cat->name ) . '" ' . '>' . $cat->name.'</a>'; |
|
| 125 | + } |
|
| 126 | + if(!empty($cats)){ ?> |
|
| 127 | 127 | <span class="post-meta-categories"><span><?php _e('Posted in:','lsx'); ?></span> <?php echo implode(', ', $cats); ?></span> |
| 128 | 128 | <?php } ?> |
| 129 | 129 | |
@@ -410,7 +410,7 @@ discard block |
||
| 410 | 410 | |
| 411 | 411 | //print_r(get_nav_menu_locations()); |
| 412 | 412 | |
| 413 | - if(false != $nav_menu && isset($nav_menu['primary']) && 0 != $nav_menu['primary']){ ?> |
|
| 413 | + if(false != $nav_menu && isset($nav_menu['primary']) && 0 != $nav_menu['primary']){ ?> |
|
| 414 | 414 | <nav class="primary-navbar collapse navbar-collapse"> |
| 415 | 415 | <?php |
| 416 | 416 | wp_nav_menu( array( |
@@ -538,9 +538,9 @@ discard block |
||
| 538 | 538 | if(null != $tag_cloud){ |
| 539 | 539 | printf( '<h2>'.__( '%1$s', 'lsx' ).'</h2>', $taxonomy ); |
| 540 | 540 | echo '<aside id="'.$taxonomy_id.'" class="widget widget_'.$taxonomy_id.'">'.$tag_cloud.'</aside>'; |
| 541 | - } |
|
| 542 | - } |
|
| 543 | - } |
|
| 541 | + } |
|
| 542 | + } |
|
| 543 | + } |
|
| 544 | 544 | } |
| 545 | 545 | |
| 546 | 546 | /** |
@@ -589,11 +589,11 @@ discard block |
||
| 589 | 589 | <div class="container"> |
| 590 | 590 | <nav class="top-menu"> |
| 591 | 591 | <?php |
| 592 | - wp_nav_menu( array( |
|
| 592 | + wp_nav_menu( array( |
|
| 593 | 593 | 'theme_location' => 'top-menu', |
| 594 | 594 | 'walker' => new lsx_bootstrap_navwalker()) |
| 595 | 595 | ); |
| 596 | - ?> |
|
| 596 | + ?> |
|
| 597 | 597 | </nav> |
| 598 | 598 | </div> |
| 599 | 599 | </div> |
@@ -46,16 +46,16 @@ |
||
| 46 | 46 | |
| 47 | 47 | function lsx_sidebar_footer_params( $params ) { |
| 48 | 48 | |
| 49 | - $sidebar_id = $params[0]['id']; |
|
| 49 | + $sidebar_id = $params[0]['id']; |
|
| 50 | 50 | |
| 51 | - if ( $sidebar_id == 'sidebar-footer' ) { |
|
| 51 | + if ( $sidebar_id == 'sidebar-footer' ) { |
|
| 52 | 52 | |
| 53 | - $total_widgets = wp_get_sidebars_widgets(); |
|
| 54 | - $sidebar_widgets = count($total_widgets[$sidebar_id]); |
|
| 53 | + $total_widgets = wp_get_sidebars_widgets(); |
|
| 54 | + $sidebar_widgets = count($total_widgets[$sidebar_id]); |
|
| 55 | 55 | |
| 56 | - $params[0]['before_widget'] = str_replace('class="styler', 'class="col-sm-' . floor(12 / $sidebar_widgets), $params[0]['before_widget']); |
|
| 57 | - } |
|
| 56 | + $params[0]['before_widget'] = str_replace('class="styler', 'class="col-sm-' . floor(12 / $sidebar_widgets), $params[0]['before_widget']); |
|
| 57 | + } |
|
| 58 | 58 | |
| 59 | - return $params; |
|
| 59 | + return $params; |
|
| 60 | 60 | } |
| 61 | 61 | add_filter( 'dynamic_sidebar_params', 'lsx_sidebar_footer_params' ); |
| 62 | 62 | \ No newline at end of file |
@@ -14,6 +14,6 @@ |
||
| 14 | 14 | */ |
| 15 | 15 | |
| 16 | 16 | function lsx_wp_job_manager_styles() { |
| 17 | - wp_enqueue_style( 'wp_job_manager', get_template_directory_uri() . '/css/wp-job-manager.css' ); |
|
| 17 | + wp_enqueue_style( 'wp_job_manager', get_template_directory_uri() . '/css/wp-job-manager.css' ); |
|
| 18 | 18 | } |
| 19 | 19 | add_action( 'wp_enqueue_scripts', 'lsx_wp_job_manager_styles' ); |
| 20 | 20 | \ No newline at end of file |