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
'save-in-separate-meta' => true, |
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
on_sent_ok: "location.replace('http://paintballgelderland.nl/boeking-dank-je-wel');" |
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 custom_search_query( $query ) { | |
$custom_fields = array( | |
// put all the meta fields you want to search for here | |
"fw_options", | |
); | |
$searchterm = $query->query_vars['s']; | |
// we have to remove the "s" parameter from the query, because it will prevent the posts from being found | |
$query->query_vars['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
<?php | |
/** | |
* Adding domains to DirectAdmin | |
*/ | |
include 'httpsocket.php'; | |
// domains comma seperated | |
$domains = 'domein1.nl,domein2.nl,domein3.nl'; |
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
# XML-RPC DDoS PROTECTION | |
<FilesMatch "^(xmlrpc\.php)"> | |
Order Deny,Allow | |
Deny from all | |
</FilesMatch> | |
# XML-RPC DDoS & TRACKBACK/PINGBACK PROTECTION | |
# Also block Pingbacks and Trackbacks | |
<FilesMatch "^(xmlrpc\.php|wp-trackback\.php)"> | |
Order Deny,Allow | |
Deny from all |
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
$buildwith = fw_ext_page_builder_is_builder_post( get_the_ID() ); | |
if($buildwith == 1){ | |
the_content(); | |
} |
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
$value = $_POST['woocommerce-sort-by-columns']; | |
add_filter( 'loop_shop_per_page', create_function( '$cols', 'return ' . $value . ';' ), 20 ); | |
function woocommerce_catalog_page_ordering($value) { | |
$amounts = array( | |
20, | |
30, | |
80, | |
160, |
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
## EXPIRES CACHING ## | |
<IfModule mod_expires.c> | |
ExpiresActive On | |
ExpiresByType image/jpg "access 1 year" | |
ExpiresByType image/jpeg "access 1 year" | |
ExpiresByType image/gif "access 1 year" | |
ExpiresByType image/png "access 1 year" | |
ExpiresByType text/css "access 1 month" | |
ExpiresByType application/pdf "access 1 month" | |
ExpiresByType text/x-javascript "access 1 month" |
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
/** | |
* Auto Complete all WooCommerce orders. | |
* Add to theme functions.php file | |
*/ | |
add_action( 'woocommerce_thankyou', 'custom_woocommerce_auto_complete_order', 1, 1 ); | |
function custom_woocommerce_auto_complete_order( $order_id ) { | |
global $woocommerce; | |
if ( !$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
add_filter( 'woocommerce_email_headers', 'add_bcc_to_wc_admin_new_order', 10, 3 ); | |
function add_bcc_to_wc_admin_new_order( $headers = '', $id = '', $wc_email = array() ) { | |
if ( $id == 'customer_completed_order' ) { | |
$headers .= "Bcc: [email protected]\r\n"; // replace [email protected] with your email | |
} | |
return $headers; | |
} |
NewerOlder