This file contains hidden or 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
| // === Freebie: “Synthetica” One Page Website Template (HTML, Sketch) == | |
| // http://tympanus.net/codrops/2016/04/29/freebie-synthetica-one-page-website-template/ | |
| ==== _colors.scss === | |
| $white: #ffffff; //white | |
| $black: #000000; //black | |
| $slate: #414A52; //body font | |
| $light-slate: #5E6265; | |
| $light-grey: #F4F6F9; //light section | |
| $dark-grey: #8A9097; |
This file contains hidden or 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
| $(document).ready(function(){ | |
| $('form#contact-form').submit(function(e){ | |
| e.preventDefault(); | |
| var msg = $(this).serialize(); | |
| var action = $(this).attr('action'); | |
| $.ajax({ | |
| type: "POST", | |
| url: action, | |
| data: msg, | |
| success: function(data) { |
This file contains hidden or 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 | |
| $tvid = 9; | |
| $res = array(); | |
| $temp = array(); | |
| $output = ''; | |
| $q = $modx->newQuery('modTemplateVarResource', array('tmplvarid' => $tvid)); | |
| $q -> select('contentid, value'); | |
| if ($q->prepare() && $q->stmt->execute()) { | |
| while ($row = $q->stmt->fetch(PDO::FETCH_ASSOC)) { |
This file contains hidden or 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
| ================================ SQL.php -класс для работы с БД. Bспользутся PDO ======================================== | |
| ==== PHP Data Objects. Данное расширение предоставляет доступ к Базам Данных используя объекты ======= | |
| <?php | |
| class SQL { | |
| private static $instance = null; | |
| private $db ; | |
| public static function Instance() { |
This file contains hidden or 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
| <!-- Ускоряем загрузку: фоновая загрузка Яндекс.Карты - https://www.megaindex.org/speed --> | |
| <meta http-equiv="x-dns-prefetch-control" content=""> | |
| <link rel="dns-prefetch" href="https://api-maps.yandex.ru/services/constructor/1.0/js/"> |
This file contains hidden or 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
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>Typed effect</title> | |
| </head> | |
| <body> | |
| <div class="element"></div> |
This file contains hidden or 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 | |
| // Добавление дополнительных полей к таксономии $taxname | |
| // и создание фильтра для вывод пользовательского поля title в заголовок страницы архива | |
| // Название (слаг, id ) таксономии, к которой будем добавлять поля | |
| $taxname = 'product_cat'; | |
| // Поля при добавлении элемента таксономии | |
| add_action("{$taxname}_add_form_fields", 'add_new_custom_fields'); | |
| // Поля при редактировании элемента таксономии |
This file contains hidden or 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
| // Background Parallax | |
| var $window = $(window); | |
| if($('section[data-type="background"]').length){ | |
| $('section[data-type="background"]').each(function(){ | |
| var $obj = $(this); | |
| var offset = $obj.offset().top; | |
| $(window).scroll(function() | |
| { |
This file contains hidden or 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 | |
| /* | |
| Идущий НИЖЕ код можно вставить в файл custom_functions.php или ВЕСЬ файл подключить в custom_functions.php, используя код | |
| if(file_exists(dirname( __FILE__ ).'/select_product_cat_template.php')){ include_once 'select_product_cat_template.php'; } | |
| */ | |
| add_action('template_redirect', 'select_product_cat_template'); | |
| function select_product_cat_template() { |