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
add_filter( 'dgwt/wcas/search_query/args', function ( $args ) { | |
$args = array( | |
'post_status' => 'publish', | |
'meta_query' => array( | |
array( | |
'key' => '_visibility', | |
'value' => array('visible'), | |
'compare' => 'IN' | |
) | |
) |
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
add_action('woocommerce_order_status_changed', 'custom_increase_stock_on_failed_and_cancelled_order', 10, 4 ); | |
function custom_increase_stock_on_failed_and_cancelled_order( $order_id, $old_status, $new_status, $order ){ | |
if ( $new_status == 'cancelled' || $new_status == 'failed' ){ | |
wc_maybe_increase_stock_levels( $order_id ); | |
} | |
} |
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
Part 1 | |
1. 30 | |
2. 12Fizz4BuzzFizz78FizzBuzz11Fizz1314FizzBuzz1617Fizz19BuzzFizz2223FizzBuzz26Fizz2829FizzBuzz3132Fizz34BuzzFizz3738FizzBuzz41Fizz4344FizzBuzz4647Fizz49BuzzFizz5253FizzBuzz56Fizz5859FizzBuzz6162Fizz64BuzzFizz6768FizzBuzz71Fizz7374FizzBuzz7677Fizz79BuzzFizz8283FizzBuzz86Fizz8889FizzBuzz9192Fizz94BuzzFizz9798Fizz | |
<?php | |
$foo = range(0 ,100); | |
for($i=1;$i < 100;$i++){ | |
if($i % 3 == 0){ | |
$foo[$i]="Fizz"; |