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
function get_filtered_price() { | |
global $wpdb; | |
$args = wc()->query->get_main_query(); | |
$tax_query = isset( $args->tax_query->queries ) ? $args->tax_query->queries : array(); | |
$meta_query = isset( $args->query_vars['meta_query'] ) ? $args->query_vars['meta_query'] : array(); | |
foreach ( $meta_query + $tax_query as $key => $query ) { | |
if ( ! empty( $query['price_filter'] ) || ! empty( $query['rating_filter'] ) ) { |
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
update_option('wah_sidebar_widgets_order',''); |
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
<script src="https://code.jquery.com/jquery-1.12.4.min.js"></script> | |
<script type="text/javascript"> | |
var wahproConfig = { | |
user : { | |
id: 123123, // user ID | |
token : 'qwerty' // user secret token | |
}, | |
theme: { | |
name : 'dark', // dark || light | |
position : 'right', // right || left |
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 | |
$fields = array(); | |
// $dates = array of subfields to update | |
// $post_id = where to update fields | |
$repeater_key = 'field_58e1e3a5fe92f'; | |
foreach( $dates as $tour_date ) { |
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
// npm install [email protected] gulp-decompress gulp-download vinyl-ftp del gulp-open gulp-run | |
/**************************** | |
FTP Server connection | |
****************************/ | |
var ftp_host = 'devurl.net', | |
ftp_user = 'user', | |
ftp_pass = 'pass', | |
//theme_name = 'gulp-starter', | |
theme_path = './wp-content/themes/'; |
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 | |
/** | |
* WordPress Query Comprehensive Reference | |
* Compiled by luetkemj - luetkemj.com | |
* | |
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php | |
*/ | |
$args = array( |
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
//Atom Settings |
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
// add this to your theme's functions.php | |
/* | |
* Define a custom option type | |
* this type will repeat some text inputs | |
*/ | |
function repeat_text_option_type( $option_name, $option, $values ){ | |
$counter = 0; |