2021-03-28 12:12:18 +03:00

44 lines
3.3 KiB
PHP

<?php
add_action('wp_enqueue_scripts', 'armanty_get_styles');
function armanty_get_styles(){
$libs = $GLOBALS['paths']['libs'];;
$css = $GLOBALS['paths']['css'];;
$pagesStyle = $css . '/pages';
$styleVersion = $GLOBALS['version'];
wp_enqueue_style( 'styles', get_stylesheet_uri());
wp_enqueue_style('fonts', "https://fonts.googleapis.com/css?family=PT+Sans:400,700&display=swap&subset=cyrillic", array(), $styleVersion);
wp_enqueue_style('my_fonts', $css . '/fonts.css', array(), $styleVersion);
wp_enqueue_style('fontawesome', $libs . '/font-awesome-4.7.0/css/font-awesome.min.css', array(), $styleVersion);
wp_enqueue_style('bootstrap', $libs . '/bootstrap-4.4.1-dist/css/bootstrap.min.css', array(), $styleVersion);
wp_enqueue_style('owlcarousel', $libs . '/OwlCarousel2-2.3.4/dist/assets/owl.carousel.min.css', array(), $styleVersion);
if(is_page ('59')){
wp_enqueue_style('btdtpicker', $libs . '/bootstrap_datetimepicker/css/bootstrap.min.css', array(), $styleVersion);
}
wp_enqueue_style('dtpicker', $libs . '/bootstrap_datetimepicker/css/bootstrap-datetimepicker.min.css', array(), $styleVersion);
wp_enqueue_style('bootstrapselect', $libs . '/bootstrap-select/bootstrap-select.min.css', array(), $styleVersion);
wp_enqueue_style('slick', 'http://cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.css', array(), $styleVersion);
wp_enqueue_style('armanty_other', $css . '/other.css', array(), $styleVersion);
wp_enqueue_style('armanty_style', $css . '/style.css', array(), $styleVersion);
if (is_page_template('templates/about.php')) wp_enqueue_style('armanty_about', $pagesStyle . '/about.css', array(), $styleVersion);
if (is_page_template('templates/certificates.php')) wp_enqueue_style('armanty_certificates', $pagesStyle . '/certificates.css', array(), $styleVersion);
if (is_page_template('templates/contacts.php')) wp_enqueue_style('armanty_contacts', $pagesStyle . '/contacts.css', array(), $styleVersion);
if (is_page_template('templates/form.php')) wp_enqueue_style('armanty_form', $pagesStyle . '/form.css', array(), $styleVersion);
if (is_page_template('templates/gallery.php')) wp_enqueue_style('armanty_gallery', $pagesStyle . '/gallery.css', array(), $styleVersion);
if (is_page_template('templates/home.php')) wp_enqueue_style('armanty_home', $pagesStyle . '/home.css', array(), $styleVersion);
if (is_page_template('templates/price.php')) wp_enqueue_style('armanty_price', $pagesStyle . '/price.css', array(), $styleVersion);
if (is_page_template('templates/quests.php')) wp_enqueue_style('armanty_quests', $pagesStyle . '/quests.css', array(), $styleVersion);
if (is_page_template('templates/sales.php')) wp_enqueue_style('armanty_sales', $pagesStyle . '/sales.css', array(), $styleVersion);
if (is_page_template('templates/single-quest.php')) wp_enqueue_style('armanty_single-quest', $pagesStyle . '/single-quest.css', array(), $styleVersion);
if (is_page_template('templates/graduation.php')) wp_enqueue_style('armanty_graduation', $pagesStyle . '/graduation.css', array(), $styleVersion);
wp_enqueue_style('armanty_holiday', $pagesStyle . '/holiday.css', array(), $styleVersion);
wp_enqueue_style('armanty_quests', $pagesStyle . '/quests.css', array(), $styleVersion);
}
?>