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
/* Sorurce: http://codepen.io/Rowno/pen/Afykb */ | |
.carousel-fade { | |
.carousel-inner { | |
.item { | |
transition-property: opacity; | |
} | |
.item, | |
.active.left, | |
.active.right { |
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 | |
add_filter('posts_search', function ($search, &$wp_query) { | |
global $wpdb; | |
if (empty($search) || is_admin()) { | |
return $search; // skip processing - no search term in query | |
} | |
$s = get_query_var('s'); |
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 WP_Ajax alias | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteRule ^alias.php$ wp-admin/admin-ajax.php?%{QUERY_STRING} [L] | |
</IfModule> | |
# BEGIN WP_Ajax alias |
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 | |
// Ensure cart contents update when products are added to the cart via AJAX (place the following in functions.php) | |
add_filter( 'woocommerce_add_to_cart_fragments', 'woocommerce_header_add_to_cart_fragment' ); | |
function woocommerce_header_add_to_cart_fragment( $fragments ) { | |
ob_start(); | |
?> | |
<a class="cart-contents" href="<?php echo WC()->cart->get_cart_url(); ?>" title="<?php _e( 'View your shopping cart' ); ?>"><?php echo sprintf (_n( '%d item', '%d items', WC()->cart->cart_contents_count ), WC()->cart->cart_contents_count ); ?> - <?php echo WC()->cart->get_cart_total(); ?></a> | |
<?php |
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 | |
add_action('wp_ajax_envialosimple_member_edit', function() { | |
// Get the results | |
$baseURL = 'https://app.envialosimple.com'; | |
$apiKey = ''; | |
$remote_url = $baseURL . '/member/edit/format/json'; | |
$params = array(); |
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
$(function () { | |
jQuery('#formID').validationEngine('attach', { | |
showPrompts: false, | |
showArrow: false | |
}).bind("jqv.field.result", function (event, field, errorFound, prompText) { | |
var formGroup = field.parents(".form-group"); | |
formGroup.removeClass("has-feedback has-error has-success"); | |
if (errorFound) { | |
formGroup.addClass("has-feedback has-error"); | |
jQuery(formGroup).find("span.help-block, span.form-control-feedback").remove(); |
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
(function ($) { | |
$.fn.ajaxFormSubmit = function (options) { | |
var settings = $.extend({ | |
alertContainer: '', | |
callback: null | |
}, options); | |
if (typeof admin_url === 'undefined') | |
return this; | |
var fields = $(this).find('input, select, textarea').not(':disabled'); |
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
<form id="registerform" method="post" action="<?php home_url() ?>" name="loginform"> | |
<div class="form-group"> | |
<label for="user_login">Email</label> | |
<input type="text" class="form-control" name="user_login" id="user_login" placeholder="Tu email"> | |
</div> | |
<div class="form-group"> | |
<label for="user_password">Contraseña</label> | |
<input type="password" class="form-control" id="user_password" name="user_password" placeholder="Contraseña"> | |
</div> | |
<div class="form-group"> |
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 | |
add_filter('rwmb_meta_boxes', function ($meta_boxes) { | |
$meta_boxes[] = array( | |
'id' => 'gallery', | |
'title' => 'Galería', | |
'pages' => array('page'), | |
'context' => 'normal', | |
'priority' => 'high', | |
'fields' => array( |