view-slider/index.php000064400000014464150212224120010616 0ustar00 'splide__slide']); } // if ($itemSource == "posts") { // $items = post_grid_builder_post_query_items($itemQueryArgs); // } // if ($itemSource == "terms") { // $items = post_grid_terms_query_item($itemQueryArgs); // } wp_enqueue_style('splide_core'); wp_enqueue_script('splide.min'); wp_enqueue_script('post-grid-slider-front'); $reponsiveCss = isset($PostGridData["reponsiveCss"]) ? $PostGridData["reponsiveCss"] : ""; $sliderOptions = isset($PostGridData['sliderOptions']) ? $PostGridData['sliderOptions'] : []; $sliderOptionsRes = isset($PostGridData['sliderOptionsRes']) ? $PostGridData['sliderOptionsRes'] : []; //var_dump($reponsiveCss); $PostGridBuilderCss .= $reponsiveCss; $wrapper = isset($PostGridData["wrapper"]) ? $PostGridData["wrapper"] : []; $wrapperOptions = isset($wrapper["options"]) ? $wrapper["options"] : []; $wrapperTag = !empty($wrapperOptions["tag"]) ? $wrapperOptions["tag"] : "div"; $wrapperClass = isset($wrapperOptions["class"]) ? $wrapperOptions["class"] : ""; $navsWrap = isset($PostGridData["navsWrap"]) ? $PostGridData["navsWrap"] : []; $navItem = isset($PostGridData["navItem"]) ? $PostGridData["navItem"] : []; $prev = isset($PostGridData["prev"]) ? $PostGridData["prev"] : []; $prevIcon = isset($PostGridData["prevIcon"]) ? $PostGridData["prevIcon"] : []; $next = isset($PostGridData["next"]) ? $PostGridData["next"] : []; $nextIcon = isset($PostGridData["nextIcon"]) ? $PostGridData["nextIcon"] : []; $paginationWrap = isset($PostGridData["paginationWrap"]) ? $PostGridData["paginationWrap"] : []; $paginationItem = isset($PostGridData["paginationItem"]) ? $PostGridData["paginationItem"] : []; $paginationItemActive = isset($PostGridData["paginationItemActive"]) ? $PostGridData["paginationItemActive"] : []; $prevIconLibrary = isset($options['library']) ? $options['library'] : ''; $prevIconSrcType = isset($options['srcType']) ? $options['srcType'] : ''; $prevIconSrc = isset($options['iconSrc']) ? $options['iconSrc'] : ''; $prevIconHtml = ''; $nextIconLibrary = isset($options['library']) ? $options['library'] : ''; $nextIconSrcType = isset($options['srcType']) ? $options['srcType'] : ''; $nextIconSrc = isset($options['iconSrc']) ? $options['iconSrc'] : ''; $nextIconHtml = ''; $sliderOptionsResNew = []; foreach ($sliderOptionsRes as $id => $arg) { foreach ($arg as $view => $value) { if ($view == 'Desktop') { $viewNum = '1280'; } if ($view == 'Tablet') { $viewNum = '991'; } if ($view == 'Mobile') { $viewNum = '767'; } $sliderOptionsResNew[$viewNum][$id] = $value; } } $sliderOptions['breakpoints'] = $sliderOptionsResNew; $blockId = "post-grid-" . $post_id; //echo "
" . var_export($loopLayouts, true) . "
"; $PostGridDataAttr = [ "id" => $blockId, "lazyLoad" => $lazyLoad, ]; $prevIconPosition = ''; $prevText = 'Prev'; $nextIconPosition = ''; $nextText = 'Next'; ?>
">
{ var dataSplideargs = item.getAttribute("data-splide"); var dataSplideargsObj = JSON.parse(dataSplideargs); var splide = new Splide('#' + item.id); splide.mount(); }) } }); view-grid/index.php000064400000004457150212224120010262 0ustar00" . var_export($loopLayouts, true) . ""; $PostGridDataAttr = [ "id" => $blockId, "lazyLoad" => $lazyLoad, ]; ?>
role="tablist" style="">
{ element.classList.remove("animate__animated", `animate__${animate_name}`); }, duration); } listenUrlHash() { var hash = window.location.hash; var hashWrap = document.querySelector('[href="' + hash + '"]'); if (hashWrap == null) return; var header = hashWrap.parentElement; var index = header.getAttribute("index") this.switch(index) } activeByIndex(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); this.activeIndex = index var content = header.nextElementSibling; if (loopIndex == index) { header.classList.toggle("accordion-header-active"); content.style.display = "block"; content.style.height = "auto"; var iconToggle = header.querySelector(".accordion-icon-toggle"); var iconIdle = header.querySelector(".accordion-icon-idle"); if (header.classList.contains("accordion-header-active")) { if (iconToggle != null) { iconToggle.style.display = "inline-block"; this.animate(iconToggle, this.iconInAnimation, this.iconAnimationDuration) } if (iconIdle != null) { iconIdle.style.display = "none"; this.animate(iconIdle, this.iconOutAnimation, this.iconAnimationDuration) } content.style.display = "block"; content.style.height = "auto"; this.animate(content, this.contentInAnimation, this.contentAnimationDuration) } else { if (iconIdle != null) { iconIdle.style.display = "inline-block"; } if (iconToggle != null) { iconToggle.style.display = "none"; } this.animate(content, this.contentOutAnimation, this.contentAnimationDuration) } } }); } inactiveByIndex(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); var content = header.nextElementSibling; if (loopIndex == index) { header.classList.toggle("accordion-header-active"); //content.style.display = "none"; //content.style.height = 0; } var iconToggle = header.querySelector(".accordion-icon-toggle"); var iconIdle = header.querySelector(".accordion-icon-idle"); if (header.classList.contains("accordion-header-active")) { if (iconToggle != null) { iconToggle.style.display = "inline-block"; this.animate(iconToggle, this.iconInAnimation, this.iconAnimationDuration) } if (iconIdle != null) { iconIdle.style.display = "none"; this.animate(iconIdle, this.iconOutAnimation, this.iconAnimationDuration) } content.style.display = "block"; content.style.height = "auto"; this.animate(content, this.contentInAnimation, this.contentAnimationDuration) } else { if (iconIdle != null) { iconIdle.style.display = "inline-block"; } if (iconToggle != null) { iconToggle.style.display = "none"; } content.style.display = "none"; this.animate(content, this.contentOutAnimation, this.contentAnimationDuration) } }); } hideByIndex(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); if (index == loopIndex) { var content = header.nextElementSibling; //content.style.display = "none"; header.style.display = "none"; } }); } unhideByIndex(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); if (index == loopIndex) { var content = header.nextElementSibling; //content.style.display = "block"; header.style.display = "flex"; } }); } unhideAll(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); var content = header.nextElementSibling; content.style.display = "none"; header.style.display = "flex"; }); } switch(index) { if (this.id.length == 0) return; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); this.activeIndex = index var content = header.nextElementSibling; if (loopIndex == index) { header.classList.toggle("accordion-header-active"); content.style.display = "block"; content.style.height = "auto"; } else { header.classList.remove("accordion-header-active"); content.style.display = "none"; content.style.height = 0; } var iconToggle = header.querySelector(".accordion-icon-toggle"); var iconIdle = header.querySelector(".accordion-icon-idle"); if (header.classList.contains("accordion-header-active")) { if (iconToggle != null) { iconToggle.style.display = "inline-block"; this.animate(iconToggle, this.iconInAnimation, this.iconAnimationDuration) } if (iconIdle != null) { iconIdle.style.display = "none"; this.animate(iconIdle, this.iconOutAnimation, this.iconAnimationDuration) } content.style.display = "block"; content.style.height = "auto"; this.animate(content, this.contentInAnimation, this.contentAnimationDuration) } else { if (iconIdle != null) { iconIdle.style.display = "inline-block"; } if (iconToggle != null) { iconToggle.style.display = "none"; } this.animate(content, this.contentOutAnimation, this.contentAnimationDuration) content.style.display = "none"; } }); } switchNext() { var activeIndex = this.activeIndex; var max = this.headerList.length - 1; var nextIndex = (activeIndex + 1 > max) ? 0 : (activeIndex + 1); this.switch(nextIndex); } switchPrev() { var activeIndex = this.activeIndex; var max = this.headerList.length - 1; var nextIndex = (activeIndex - 1 < 0) ? max : (activeIndex - 1); this.switch(nextIndex); } autoPlayRun() { let currentIndex = -1; const loopThroughItems = () => { var length = this.headerList.length + 1; currentIndex = (currentIndex + 1) % length; this.switch(currentIndex); setTimeout(loopThroughItems, this.autoPlayDelay); }; if (this.autoPlay) loopThroughItems(); } search(keyword) { if (keyword.length == 0) { this.unhideAll() return; } var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); accordionHeaders.forEach((header, i) => { var loopIndex = header.getAttribute("index"); //this.activeIndex = index var content = header.nextElementSibling; var headerLabel = header.querySelector(".accordion-header-label"); var labelText = headerLabel.innerText.toLowerCase();; var contentText = content.innerText.toLowerCase();; var searchContent = labelText + " " + contentText var position = searchContent.indexOf(keyword); if (position < 0) { this.hideByIndex(loopIndex) } else { this.unhideByIndex(loopIndex) } }); } expandCollapseAll() { var expandCollapseAllHndle = document.querySelector("#" + this.id + " " + this.expandCollapseAllHndle); var toggled = expandCollapseAllHndle.getAttribute("data-toggled"); var headerCount = this.headerList.length var expandCollapseAllDelay = parseInt(this.expandCollapseAllDelay); var expandalltext = expandCollapseAllHndle.getAttribute("data-expandalltext"); var collapsealltext = expandCollapseAllHndle.getAttribute("data-collapsealltext"); var expandalliconhtml = expandCollapseAllHndle.getAttribute("data-expandalliconhtml"); var collapsealliconhtml = expandCollapseAllHndle.getAttribute("data-collapsealliconhtml"); if (!toggled) { expandCollapseAllHndle.setAttribute("data-toggled", true); var innerHtml = `${collapsealliconhtml}${collapsealltext}`; var _this = this; for (var i = 0; i < headerCount; i++) { (function (index) { setTimeout(function () { _this.activeByIndex(index) }, expandCollapseAllDelay * index); })(i); } } else { var _this = this; for (var i = 0; i < headerCount; i++) { (function (index) { setTimeout(function () { _this.inactiveByIndex(index) }, expandCollapseAllDelay * index); })(i); } expandCollapseAllHndle.removeAttribute("data-toggled"); var innerHtml = `${expandalliconhtml}${expandalltext}`; } expandCollapseAllHndle.innerHTML = innerHtml } init() { const accordionWrapper = document.querySelector(`#${this.id}`); if (this.lazyLoad) accordionWrapper.style.display = "block"; var accordionHeaders = document.querySelectorAll("#" + this.id + " > .accordion-header"); var headerList = []; accordionHeaders.forEach((header, index) => { var headerId = header.getAttribute("id"); headerList.push(headerId) header.setAttribute("index", index); const counter = header.querySelector(".accordion-label-counter"); if (counter !== null) { counter.textContent = `${index + 1}`; // Adding 1 to start counting from 1 } }); this.headerList = headerList; accordionHeaders.forEach((accordionHeader) => { var iconToggle = accordionHeader.querySelector(".accordion-icon-toggle"); var iconIdle = accordionHeader.querySelector(".accordion-icon"); if (iconToggle != null) { iconToggle.style.display = "none"; } }); if (accordionHeaders != null) { accordionHeaders.forEach((accordionHeader) => { // var fieldId = accordionHeader.getAttribute("id"); var content = accordionHeader.nextElementSibling; var iconToggle = accordionHeader.querySelector(".accordion-icon-toggle"); var iconIdle = accordionHeader.querySelector(".accordion-icon-idle"); if (iconToggle != null) { iconToggle.style.display = "none"; } if (content != undefined) { content.style.height = 0; content.style.overflow = "hidden"; content.style.display = "none"; } accordionHeader.addEventListener("click", (event) => { event.stopImmediatePropagation(); event.preventDefault(); //accordionHeader.scrollIntoView({ behavior: 'smooth' }); if (this.clickToScrollTop) { var offset = this.clickToScrollTopOffset; const elementPosition = accordionHeader.getBoundingClientRect().top + window.scrollY; const offsetPosition = elementPosition - offset; window.scrollTo({ top: offsetPosition, behavior: 'smooth' }); } var loopIndex = accordionHeader.getAttribute("index"); if (this.keepExpandOther) { this.activeByIndex(loopIndex); } else { this.switch(loopIndex); } }); }); } if (this.activeIndex.length > 1) { this.activeIndex.map((index) => { this.activeByIndex(index); }) } if (this.urlHash) this.listenUrlHash(); if (this.autoPlay) this.autoPlayRun(); if (this.expandCollapseAllEnable) { var expandCollapseAllHndle = document.querySelector("#" + this.id + " " + this.expandCollapseAllHndle); if (expandCollapseAllHndle != null) { var _this = this; expandCollapseAllHndle.addEventListener("click", function (event) { _this.expandCollapseAll(); }) } } if (this.searchEnable) { var _this = this; var searchHndle = document.querySelector("#" + this.id + " .search-input"); if (searchHndle != null) { function debounce(func, delay) { let timeout; return function (...args) { clearTimeout(timeout); timeout = setTimeout(() => func.apply(this, args), delay); }; } function handleKeyup(event) { event.preventDefault(); var value = event.target.value; _this.search(value) } searchHndle.addEventListener('keyup', debounce(handleKeyup, 500)); } } } } // Initialize instances document.querySelectorAll("[data-accordionBuilder]").forEach((tabElement) => { const config = JSON.parse(tabElement.getAttribute("data-accordionBuilder")); new AccordionBuilder(config); }); }); post-grid-hook.php000064400000214652150212224120010124 0ustar00
<?php echo esc_attr($lazy_load_alt_text); ?>
taxonomy) ? $term->taxonomy : ''; $term_id = isset($term->term_id) ? $term->term_id : ''; $post_grid_js_args['page_type'] = 'taxonomy'; $post_grid_js_args['page_taxonomy'] = $taxonomy; $post_grid_js_args['page_tax_term'] = $term_id; } $post_grid_js_args['id'] = $grid_id; $post_grid_js_args['lazy_load'] = $lazy_load_enable; $post_grid_js_args['masonry_enable'] = $masonry_enable; $post_grid_js_args['view_type'] = $grid_type; $post_grid_js_args = apply_filters('post_grid_js_args', $post_grid_js_args, $args); ?>
'; } elseif ($font_aw_version == 'v_4') { $nav_top_search_icon = ''; } // if($grid_id != 2147) return; // 7 is grid ID where you want to display this input field $nav_top_search_placeholder = isset($post_grid_options['nav_top']['search_placeholder']) ? $post_grid_options['nav_top']['search_placeholder'] : __('Start typing', 'post-grid'); $nav_top_search_icon = isset($post_grid_options['nav_top']['search_icon']) ? $post_grid_options['nav_top']['search_icon'] : $nav_top_search_icon; $keyword = isset($_GET['keyword']) ? sanitize_text_field($_GET['keyword']) : ''; ?>
'; } elseif ($font_aw_version == 'v_4') { $nav_top_search_icon = ''; } // if($grid_id != 2147) return; // 7 is grid ID where you want to display this input field $nav_top_search_placeholder = isset($post_grid_options['nav_top']['search_placeholder']) ? $post_grid_options['nav_top']['search_placeholder'] : __('Start typing', 'post-grid'); $nav_top_search_icon = isset($post_grid_options['nav_top']['search_icon']) ? $post_grid_options['nav_top']['search_icon'] : $nav_top_search_icon; $search_loading_icon = isset($post_grid_options['nav_top']['search_loading_icon']) ? $post_grid_options['nav_top']['search_loading_icon'] : ''; ?>
$taxonomyData) { $terms = !empty($taxonomyData['terms']) ? $taxonomyData['terms'] : array(); $terms_relation = !empty($taxonomyData['terms_relation']) ? $taxonomyData['terms_relation'] : 'OR'; $checked = !empty($taxonomyData['checked']) ? $taxonomyData['checked'] : ''; if (!empty($terms) && !empty($checked)) { $tax_query[] = array( 'taxonomy' => $taxonomy, 'field' => 'term_id', 'terms' => $terms, 'operator' => $terms_relation, ); } } $tax_query_relation = array('relation' => $categories_relation); $tax_query = array_merge($tax_query_relation, $tax_query); /* ################################ Keyword query ######################################*/ //$keyword = isset($_GET['keyword']) ? sanitize_text_field($_GET['keyword']) : $keyword; /* ################################ Single pages ######################################*/ if (is_singular()) : $current_post_id = get_the_ID(); $query_args['post__not_in'] = array($current_post_id); endif; if (get_query_var('paged')) { $paged = get_query_var('paged'); } elseif (get_query_var('page')) { $paged = get_query_var('page'); } else { $paged = 1; } if ($ignore_paged == 'yes') { $paged = 1; } if (!empty($post_types)) $query_args['post_type'] = $post_types; if (!empty($post_status)) $query_args['post_status'] = $post_status; if (!empty($keyword)) $query_args['s'] = $keyword; if (!empty($exclude_post_id)) $query_args['post__not_in'] = $exclude_post_id; if (!empty($include_post_id)) $query_args['post__in'] = $include_post_id; if (!empty($query_order)) $query_args['order'] = $query_order; if (!empty($query_orderby)) $query_args['orderby'] = $query_orderby; if (!empty($query_orderby_meta_key)) $query_args['meta_key'] = $query_orderby_meta_key; if (!empty($posts_per_page)) $query_args['posts_per_page'] = (int)$posts_per_page; if (!empty($paged)) $query_args['paged'] = $paged; if (!empty($offset)) $query_args['offset'] = $offset + (($paged - 1) * $posts_per_page); if (!empty($tax_query)) $query_args['tax_query'] = $tax_query; if (!empty($_GET['lang'])) $query_args['lang'] = sanitize_text_field($_GET['lang']); $query_args = apply_filters('post_grid_filter_query_args', $query_args, $grid_id); $query_args = apply_filters('post_grid_query_args', $query_args, $args); $post_grid_wp_query = new WP_Query($query_args); $wp_query = $post_grid_wp_query; $loop_count = 0; if ($post_grid_wp_query->have_posts()) : do_action('post_grid_loop_top', $args); ?>
have_posts()) : $post_grid_wp_query->the_post(); $post_id = get_the_ID(); $args['post_id'] = $post_id; $args['loop_count'] = $loop_count; do_action('post_grid_loop', $args); $loop_count++; endwhile; do_action('post_grid_after_loop', $args); ?>
layout_content($layout_content); } else { if (!empty($post_grid_layout_content[$layout_content])) { $layout = $post_grid_layout_content[$layout_content]; } else { $layout = array(); } } ?>
$element) { $element_id = isset($element['key']) ? $element['key'] : ''; if (empty($element_id)) return; $element_args['element'] = $element; $element_args['index'] = $elementIndex; $element_args['post_id'] = $post_id; $element_args['layout_id'] = $post_id; do_action('post_grid_layout_element_' . $element_id, $element_args); } ?>
layout_content($layout_content); } else { if (!empty($post_grid_layout_content[$layout_content])) { $layout = $post_grid_layout_content[$layout_content]; } else { $layout = array(); } } ?> $elementData) { foreach ($elementData as $elementId => $element) { $element_args['element'] = $element; $element_args['index'] = $elementIndex; $element_args['post_id'] = $post_id; $element_args['layout_id'] = $layout_id; do_action('post_grid_layout_element_' . $elementId, $element_args); } } } add_action('post_grid_loop_bottom', 'post_grid_loop_bottom_pagination', 10, 2); function post_grid_loop_bottom_pagination($args, $post_grid_wp_query) { $post_grid_options = $args['options']; $pagination_type = isset($post_grid_options['nav_bottom']['pagination_type']) ? $post_grid_options['nav_bottom']['pagination_type'] : 'normal'; $grid_type = !empty($post_grid_options['grid_type']) ? $post_grid_options['grid_type'] : 'grid'; $nav_top = !empty($post_grid_options['nav_top']) ? $post_grid_options['nav_top'] : []; $action_type = !empty($post_grid_options['action_type']) ? $post_grid_options['action_type'] : 'form_submit'; if ($pagination_type == 'none') return; $pagination_type = ($action_type == 'ajax') ? 'ajax_pagination' : $pagination_type; $pagination_type = ($grid_type == 'filterable') ? 'jquery' : $pagination_type; wp_enqueue_script('scrollto'); ?> max_num_pages) ? $post_grid_wp_query->max_num_pages : 0; $pagination_prev_text = !empty($post_grid_options['pagination']['prev_text']) ? $post_grid_options['pagination']['prev_text'] : __('« Previous', 'post-grid'); $pagination_next_text = !empty($post_grid_options['pagination']['next_text']) ? $post_grid_options['pagination']['next_text'] : __('Next »', 'post-grid'); $pagination_max_num_pages = !empty($post_grid_options['pagination']['max_num_pages']) ? $post_grid_options['pagination']['max_num_pages'] : $max_num_pages; $pagination_font_size = !empty($post_grid_options['pagination']['font_size']) ? $post_grid_options['pagination']['font_size'] : '17px'; $pagination_font_color = !empty($post_grid_options['pagination']['font_color']) ? $post_grid_options['pagination']['font_color'] : '#646464'; $pagination_bg_color = !empty($post_grid_options['pagination']['bg_color']) ? $post_grid_options['pagination']['bg_color'] : '#646464'; $pagination_active_bg_color = !empty($post_grid_options['pagination']['active_bg_color']) ? $post_grid_options['pagination']['active_bg_color'] : '#4b4b4b'; ?>
str_replace($big, '%#%', esc_url(get_pagenum_link($big))), 'format' => '?paged=%#%', 'current' => max(1, $paged), 'total' => $pagination_max_num_pages, 'prev_text' => $pagination_prev_text, 'next_text' => $pagination_next_text, ) ); ?>
$elementData) { foreach ($elementData as $elementId => $element) { $element_args['element'] = $element; $element_args['index'] = $elementIndex; //$element_args['post_id'] = $post_id; $element_args['layout_id'] = $layout_id; //ob_start(); do_action('post_grid_layout_element_css_' . $elementId, $element_args); //$element_css .= ob_get_clean(); } } ?> $item) { $custom_class = isset($item['custom_class']) ? $item['custom_class'] : ''; $char_limit = isset($item['char_limit']) ? $item['char_limit'] : ''; $key = isset($item['key']) ? $item['key'] : ''; $css = isset($item['css']) ? $item['css'] : ''; $css_hover = isset($item['css_hover']) ? $item['css_hover'] : ''; $read_more_text = isset($item['read_more_text']) ? $item['read_more_text'] : ''; $link_target = isset($item['link_target']) ? $item['link_target'] : ''; $five_star_count = isset($item['five_star_count']) ? $item['five_star_count'] : ''; $layout_elements_data[$item_count][$key]['custom_class'] = $custom_class; $layout_elements_data[$item_count][$key]['css'] = $css; $layout_elements_data[$item_count][$key]['css_hover'] = $css_hover; if ($key == 'title' || $key == 'title_link' || $key == 'excerpt' || $key == 'excerpt_read_more') { $layout_elements_data[$item_count][$key]['char_limit'] = $char_limit; $layout_elements_data[$item_count][$key]['link_to'] = 'post_link'; } if ($key == 'read_more' || $key == 'excerpt_read_more') { $layout_elements_data[$item_count][$key]['read_more_text'] = $read_more_text; } if ($key == 'read_more' || $key == 'excerpt_read_more' || $key == 'title_link') { $layout_elements_data[$item_count][$key]['link_target'] = $link_target; $layout_elements_data[$item_count][$key]['link_to'] = 'post_link'; } if ($key == 'five_star') { $layout_elements_data[$item_count][$key]['five_star_count'] = $five_star_count; } $item_count++; } $layout_elements_data[$item_count]['wrapper_end']['wrapper_id'] = ''; $post_grid_title = get_the_title($grid_id); $post_args = array( 'post_title' => $post_grid_title . ' - ' . $layout_skin . ' - ' . $content_layout, 'post_type' => 'post_grid_layout', 'post_status' => 'publish', 'post_author' => 1, ); $new_layout_id = wp_insert_post($post_args); $custom_scripts['custom_css'] = post_grid_layout_css($layout_skin); $custom_scripts['custom_js'] = ''; $layout_options['layout_preview_img'] = ''; update_post_meta($new_layout_id, 'layout_elements_data', $layout_elements_data); update_post_meta($new_layout_id, 'custom_scripts', $custom_scripts); update_post_meta($new_layout_id, 'layout_options', $layout_options); $options['layout_id'] = $new_layout_id; update_post_meta($grid_id, 'post_grid_meta_options', $options); if ($layout_converted) { ?>

Layout converted successfully, please go # this link to edit layout

Please report issue if you found any problem, create support ticket

" . var_export($masonryOptions, true) . ""; if ($itemSource == "posts") { $items = post_grid_builder_post_query_items($itemQueryArgs, $loopLayouts); } // if ($itemSource == "terms") { // $items = post_grid_terms_query_item($itemQueryArgs); // } // if ($itemSource == "easyAccordion") { // $items = post_grid_easy_accordion_query_item($itemQueryArgs); // } $PostGridDataAttr = [ "id" => $blockId, "lazyLoad" => $lazyLoad, ]; $dataBlockId = [ "blockId" => 'abc123', ]; wp_enqueue_script('jquery'); wp_enqueue_script('imagesloaded'); wp_enqueue_script('masonry'); wp_enqueue_script('masonry.min'); wp_enqueue_script('post-grid-masonry-front'); ?>
">
{ var masonryArgs = item.getAttribute("data-masonry"); var masonryArgsObj = JSON.parse(masonryArgs); var masonryOptions = masonryArgsObj; var blockargs = item.getAttribute("data-block-id"); var blockArgsObj = JSON.parse(blockargs); var blockId = blockArgsObj.blockId; // var elemX = document.querySelector(".pg" + blockId); var elemX = document.querySelector("." + blockId); if (elemX != null) { // elemX.forEach((item) => { imagesLoaded(item, function () { var msnry = new Masonry(item, masonryOptions); }); // }); } }); } }); settings-usage-shortcode.php000064400000020400150212230430012173 0ustar00

[youtube_channel]' ); ?>

settings-tools.php000064400000001723150212230430010246 0ustar00

Clear YTC Cache

To avoid page load slowdown, we provide internal YouTube Channel caching functionality. You can enable caching per widget or shortcode, and set how long cached feed for particular widget or shortcode will live.

If you wish to force clear cache before it expires (for example, you have set cache timeout to 2 days, but wish to force loading of fresh channel or playlist feed), you can force Clear All YTC Cache to remove transients from database on demand.

settings-usage.php000064400000002735150212230430010216 0ustar00

.

  1. %s', esc_html__( 'Widgets', 'youtube-channel' ) ) ); ?>
  2. [youtube_channel]' ); ?>
settings.php000064400000003504150212230430007107 0ustar00

v.

__( 'General', 'youtube-channel' ), 'video' => __( 'Video', 'youtube-channel' ), 'content' => __( 'Content', 'youtube-channel' ), 'link' => __( 'Link to Channel', 'youtube-channel' ), 'tools' => __( 'Tools', 'youtube-channel' ), 'help' => __( 'Help', 'youtube-channel' ), ); ?> '; settings_fields( sanitize_key( 'ytc_' . $active_tab ) ); do_settings_sections( sanitize_key( YTC_PLUGIN_SLUG . '_' . $active_tab ) ); submit_button(); echo ''; } elseif ( 'tools' === $active_tab ) { include_once YTC_DIR_TEMPLATES . '/settings-tools.php'; } elseif ( 'help' === $active_tab ) { include_once YTC_DIR_TEMPLATES . '/settings-usage.php'; include_once YTC_DIR_TEMPLATES . '/settings-usage-shortcode.php'; } // $active_tab != 'tools|help|support' } // ! empty ( $tabs[$active_tab] ) ?>
AttachToPost/display_tab_source.php000064400000000162150212237130013500 0ustar00
AttachToPost/display_tab.php000064400000002431150212237130012121 0ustar00
'>
'>

AttachToPost/display_tab_type.php000064400000000051150212237130013156 0ustar00
AttachToPost/tinymce_placeholder.php000064400000001027150212237130013640 0ustar00AttachToPost/attach_to_post.php000064400000001602150212237130012640 0ustar00 <?php esc_html_e( $page_title ); ?>
$tab_params ) : ?>
AttachToPost/no_display_type_selected.php000064400000000151150212237130014675 0ustar00

AttachToPost/display_settings_form.php000064400000000441150212237130014235 0ustar00
' data-defaults="">
AttachToPost/preview_tab.php000064400000000040150212237130012127 0ustar00
SinglePicture/nextgen_basic_singlepic.php000064400000005732150212237130014703 0ustar00start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); $image_size = $storage->get_original_dimensions( $image ); if ( null === $image_size ) { $image_size['width'] = $image->meta_data['width']; $image_size['height'] = $image->meta_data['height']; } $image_ratio = $image_size['width'] / $image_size['height']; $width = isset( $settings['width'] ) ? $settings['width'] : null; $height = isset( $settings['height'] ) ? $settings['height'] : null; $width = intval( $width ); $height = intval( $height ); if ( $width != null && $height != null ) { // check image aspect ratio, avoid distortions $aspect_ratio = $width / $height; if ( $image_ratio > $aspect_ratio ) { if ( $image_size['width'] > $width ) { $height = (int) round( $width / $image_ratio ); } } elseif ( $image_size['height'] > $height ) { $width = (int) round( $height * $image_ratio ); } // Ensure that height is always null, or else the image won't be responsive correctly $height = null; } elseif ( $height != null ) { $width = (int) round( $height * $image_ratio ); // Ensure that height is always null, or else the image won't be responsive correctly $height = null; } $style = null; if ( $width ) { $style .= 'max-width: ' . $width . 'px'; } if ( $height ) { $style .= 'max-height: ' . $height . 'px'; } $this->start_element( 'nextgen_gallery.image_panel', 'item', $image ); ?> end_element(); $this->end_element(); } else { ?>

No image found

0, 'class' => 'pic', 'image' => $image, ]; ?> start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>

alttext ); // phpcs:ignore ?>

include_template( 'GalleryDisplay/ImageBefore', $template_params ); ?> > <?php print esc_attr( \Imagely\NGG\Display\I18N::ngg_plain_text_alt_title_attributes( $image->alttext ) ); ?> include_template( 'GalleryDisplay/ImageAfter', $template_params ); ?>

description ); // phpcs:ignore ?>

end_element(); ?> ImageBrowser/default-view.php000064400000005402150212237130012234 0ustar00 0, 'class' => 'pic', 'image' => $image, ]; ?> start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>

alttext ); ?>

include_template( 'GalleryDisplay/ImageBefore', $template_params ); ?> > <?php print esc_attr( \Imagely\NGG\Display\I18N::ngg_plain_text_alt_title_attributes( $image->alttext ) ); ?> include_template( 'GalleryDisplay/ImageAfter', $template_params ); ?>

description ); ?>

end_element(); ?> TagCloud/nextgen_basic_tagcloud.php000064400000000327150212237130013450 0ustar00CompactAlbum/compact.php000064400000005135150212237130011252 0ustar00 start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>
entity_type ) { $anchor = $gallery->displayed_gallery->effect_code . " href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "' data-src='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-fullsize='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-thumbnail='" . esc_attr( $gallery->previewurl ) . "' data-title='" . esc_attr( $gallery->previewpic_image->alttext ) . "' data-description='" . esc_attr( stripslashes( $gallery->previewpic_image->description ) ) . "' data-image-id='" . esc_attr( $gallery->previewpic ) . "'"; } else { $anchor = "title='" . esc_attr( $gallery->title ) . "' href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "'"; } ?>

> title, \Imagely\NGG\Display\I18N::get_kses_allowed_html() ); ?>


end_element(); ?> CompactAlbum/default-view.php000064400000005365150212237130012225 0ustar00 start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>
entity_type ) { $anchor = $gallery->displayed_gallery->effect_code . " href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "'"; if ( ! isset( $gallery->no_previewpic ) ) { $anchor .= "data-src='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-fullsize='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-thumbnail='" . esc_attr( $gallery->previewurl ) . "' data-title='" . esc_attr( $gallery->previewpic_image->alttext ) . "' data-description='" . esc_attr( stripslashes( $gallery->previewpic_image->description ) ) . "' data-image-id='" . esc_attr( $gallery->previewpic ) . "'"; } } else { $anchor = "title='" . esc_attr( $gallery->title ) . "' href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "'"; } ?>

> title, \Imagely\NGG\Display\I18N::get_kses_allowed_html() ); ?>


end_element(); ?> Albums/descriptions.php000064400000000230150212237130011175 0ustar00

Albums/breadcrumbs.php000064400000001166150212237130010771 0ustar00Thumbnails/carousel-view.php000064400000007660150212237130012155 0ustar00start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?> end_element(); ?> Thumbnails/caption-view.php000064400000006620150212237130011770 0ustar00start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?> end_element(); ?> Thumbnails/index.php000064400000006056150212237130010475 0ustar00start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?> end_element(); ?> Thumbnails/default-view.php000064400000006065150212237130011762 0ustar00start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?> end_element(); ?> Slideshow/index.php000064400000005100150212237130010315 0ustar00 start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?> end_element(); ?> ExtendedAlbum/default-view.php000064400000004667150212237130012403 0ustar00 start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>
entity_type ) { $anchor = $gallery->displayed_gallery->effect_code . " href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "' data-src='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-fullsize='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-thumbnail='" . esc_attr( $gallery->previewurl ) . "' data-title='" . esc_attr( $gallery->previewpic_image->alttext ) . "' data-description='" . esc_attr( stripslashes( $gallery->previewpic_image->description ) ) . "' data-image-id='" . esc_attr( $gallery->previewpic ) . "'"; } else { $anchor = "class='gallery_link' href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "'"; } ?>
start_element( 'nextgen_gallery.image', 'item', $gallery ); ?> end_element(); ?>

galdesc, \Imagely\NGG\Display\I18N::get_kses_allowed_html() ); ?>

counter ) && $gallery->counter > 0 ) { ?>
end_element(); ?> ExtendedAlbum/extended.php000064400000004672150212237130011603 0ustar00 start_element( 'nextgen_gallery.gallery_container', 'container', $displayed_gallery ); ?>
entity_type ) { $anchor = $gallery->displayed_gallery->effect_code . " href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "' data-src='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-fullsize='" . esc_attr( $gallery->previewpic_fullsized_url ) . "' data-thumbnail='" . esc_attr( $gallery->previewurl ) . "' data-title='" . esc_attr( $gallery->previewpic_image->alttext ) . "' data-description='" . esc_attr( stripslashes( $gallery->previewpic_image->description ) ) . "' data-image-id='" . esc_attr( $gallery->previewpic ) . "'"; } else { $anchor = "class='gallery_link' href='" . \Imagely\NGG\Util\Router::esc_url( $gallery->pagelink ) . "'"; } ?>
start_element( 'nextgen_gallery.image', 'item', $gallery ); ?> end_element(); ?>

galdesc, \Imagely\NGG\Display\I18N::get_kses_allowed_html() ); ?>

counter ) && $gallery->counter > 0 ) { ?>
end_element(); ?> IGW/marketing.php000064400000001011150212237130007651 0ustar00

Widget/Display/MediaRSS.php000064400000001212150212237130011504 0ustar00 Widget/Display/Slideshow.php000064400000000271150212237130012042 0ustar00
Widget/Display/Gallery.php000064400000002554150212237130011506 0ustar00get_effect_code( $gallery->displayed_gallery ); $settings = $gallery->displayed_gallery->get_entity()->display_settings; echo $settings['widget_setting_before_widget'] . $settings['widget_setting_before_title'] . $settings['widget_setting_title'] . $settings['widget_setting_after_title']; ?>
><?php echo esc_attr( \Imagely\NGG\Display\I18N::ngg_plain_text_alt_title_attributes( $image->alttext ) ); ?>
Widget/Form/MediaRSS.php000064400000003354150212237130011013 0ustar00

Widget/Form/Slideshow.php000064400000005104150212237130011340 0ustar00

' name='get_field_name( 'title' ); ?>' type='text' value=''/>

_container' style="display: none;" > ' name='get_field_name( 'limit' ); ?>' type='number' min='0' step='1' style="padding: 3px; width: 45px;" value=""/>

' name='get_field_name( 'height' ); ?>' type='text' style='padding: 3px; width: 45px;' value=''/>

' name='get_field_name( 'width' ); ?>' type='text' style='padding: 3px; width: 45px;' value=''/>

Widget/Form/Gallery.php000064400000007555150212237130011012 0ustar00

:

:
get_field_id( 'height' ); $thumbnails_template_width_id = $self->get_field_id( 'width' ); $thumbnails_template_height_name = $self->get_field_name( 'height' ); $thumbnails_template_width_name = $self->get_field_name( 'width' ); require implode( DIRECTORY_SEPARATOR, [ rtrim( NGGALLERY_ABSPATH, '/\\' ), 'admin', 'thumbnails-template.php', ] ); ?>

GalleryDisplay/ContainerAfter.php000064400000000000150212237130013070 0ustar00GalleryDisplay/ListBefore.php000064400000000000150212237130012222 0ustar00GalleryDisplay/NoImagesFound.php000064400000000110150212237130012664 0ustar00

GalleryDisplay/Related.php000064400000001500150212237130011552 0ustar00 GalleryDisplay/ImageBefore.php000064400000000522150212237130012342 0ustar00
style ) ) { echo $image->style;} ?> >GalleryDisplay/ImageAfter.php000064400000000006150212237130012176 0ustar00
GalleryDisplay/ContainerBefore.php000064400000000000150212237130013231 0ustar00GalleryDisplay/ListAfter.php000064400000000000150212237130012061 0ustar00Admin/ReviewNotice.php000064400000002055150212237130010706 0ustar00

%1\$s, you've created %2\$d NextGEN galleries! Awesome! Could I ask you to give us a 5-star rating really quickly on WordPress.org? It helps other WordPress users and motivates us to keep improving. You can also just send us feedback here. Thanks! ~ Syed Balkhi, CEO of Imagely", 'nggallery' ), $user->display_name, $number, $review_1_anchor, 'href="https://www.imagely.com/feedback/" target="_blank"' ); ?>

> | |

single.html000064400000002736150212466400006723 0ustar00
search.html000064400000001072150212466400006677 0ustar00
archive.html000064400000000736150212466400007061 0ustar00
index.html000064400000000727150212466400006547 0ustar00
404.html000064400000001155150212466400005743 0ustar00
page.html000064400000001557150212466400006356 0ustar00
home.html000064400000000727150212466400006370 0ustar00
page-no-title.html000064400000000533150212466400010100 0ustar00