forked from LiveCarta/LiveCartaWP
Merge branch 'wordpress' of https://github.com/Teqniksoft/LawCarta_book into wordpress
This commit is contained in:
@@ -15,7 +15,7 @@ define('LAWCARTA_WP_REST_API_RESPONSE_URL', 'https://app-staging-law.carta.live/
|
||||
|
||||
define('LAWCARTA_ENVIRONMENT_NAME', 'staging');
|
||||
|
||||
//$_SERVER['HTTPS'] = 'On';
|
||||
$_SERVER['HTTPS'] = 'On';
|
||||
|
||||
//S3 uploads settings
|
||||
define( 'S3_UPLOADS_BUCKET', 'law-carta-staging-wp' );
|
||||
|
||||
@@ -250,5 +250,25 @@ function remove_width_attribute( $html ) {
|
||||
return $html;
|
||||
}
|
||||
|
||||
/* Register template redirect action callback */
|
||||
add_action('template_redirect', 'meks_remove_wp_archives');
|
||||
|
||||
/* Remove archives */
|
||||
function meks_remove_wp_archives(){
|
||||
//If we are on category or tag or date or author archive
|
||||
if( is_category() || is_tag() || is_date() || is_author() ) {
|
||||
global $wp_query;
|
||||
$wp_query->set_404(); //set to 404 not found page
|
||||
}
|
||||
}
|
||||
|
||||
add_filter('nav_menu_css_class' , 'special_nav_class' , 10 , 2);
|
||||
|
||||
function special_nav_class ($classes, $item) {
|
||||
if ($item->current){
|
||||
$classes[] = 'active ';
|
||||
}
|
||||
return $classes;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user