This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'after_setup_theme', 'theme_register_nav_menu' ); | |
function theme_register_nav_menu() { | |
register_nav_menu( 'primary', 'Primary Menu' ); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'wp_enqueue_scripts', 'theme_add_scripts' ); | |
function theme_add_scripts() { | |
//add scripts | |
wp_enqueue_script( 'main-js', get_template_directory_uri() .'/js/build.js', array('jquery'), '1.0', true ); | |
//add style | |
wp_enqueue_style( 'main-style', get_template_directory_uri() .'/css/main.css'); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if( function_exists('acf_add_options_page') ) { | |
acf_add_options_page(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if( function_exists('acf_add_options_page') ) { | |
acf_add_options_page(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Theme Name: La Strada | |
Theme URI: http://alscon-web.com | |
Author: Alex Lavihyn | |
Author URI: https://www.upwork.com/freelancers/~015d44c720e5f4462a | |
Description: Theme for the restaurant La Strada city Kharkiv | |
Version: 1.0 | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Filter output menu add sign in / sign out | |
add_filter( 'wp_nav_menu_items', 'add_loginout_link', 10, 2 ); | |
function add_loginout_link( $items, $args ) { | |
if (is_user_logged_in() && $args->theme_location == 'header_menu') { | |
$items .= '<li><a href="'. wp_logout_url(home_url()) .'"><i class="icon-user-login-button"></i><span>Выйти</span></a></li>'; | |
} | |
elseif (!is_user_logged_in() && $args->theme_location == 'header_menu') { | |
$items .= '<li><a data-fancybox="" data-animation-duration="700" data-src="#register-popup" href="javascript:;"><i class="icon-Registration-01"></i><span>Регистрация</span></a></li>'; | |
$items .= '<li><a data-fancybox="" data-animation-duration="700" data-src="#login-popup" href="javascript:;"><i class="icon-user-login-button"></i><span>Войти</span></a></li>'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# BEGIN WordPress | |
#Order Allow,Deny | |
#Deny from all | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteRule ^index\.php$ - [L] | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule . /index.php [L] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Template Name: Terms Page | |
*/ | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter('excerpt_more', function($more) { | |
return '...'; | |
}); |
NewerOlder