Layouts plugin allows you to design and customize the front-end display of your website. You can design entire pages, including header, footer, menus, content and all other elements.
When you ask for help or report issues, make sure to tell us the design that you want to achieve and the layouts that you have created so far.
Viewing 15 topics - 436 through 450 (of 493 total)
Problem: I have a custom search View that updates with AJAX. When the page loads, I use custom JavaScript to apply custom CSS classes to the parent label of a checkbox if it is checked. When the View is updated with AJAX, the CSS class disappears.
Solution: AJAX updates overwrite not only the results of a View but also the filters. You must apply the CSS class again after the AJAX update by inspecting the checkbox and determining whether or not it is checked.
jQuery(document).ready(function () {
// add class to label when input changes
jQuery(document).on('click', 'input', function () {
if (jQuery(this).is(':checked')) {
jQuery(this).parent().addClass('done');
} else {
jQuery(this).parent().removeClass('done');
}
});
// After ajax load, loop over replaced inputs and re-apply parent element classes if needed
jQuery( document ).on( 'js_event_wpv_parametric_search_form_updated', function(event,data) {
jQuery('input').each(function (index, item) {
if (jQuery(item).is(':checked')) {
jQuery(item).parent().addClass('done');
}
});
});
});
Problem: I would like to use custom JavaScript to control some tab cell elements.
Solution: Use the Bootstrap tab component API to manipulate tab selections. Here's how you might select and show the last tab in the first set of tabs on a page after clicking a link with id "btn":
Problem: I have a Form displayed on a parent post. The Form creates child posts. There is a View of child posts displayed on the parent post as well. After creating a child post and refreshing the page, the new post does not appear in the View. I cannot see the new child post until I update the parent post Layout.
Solution: This appears to be an issue with the Redis Cache plugin.