if ( is_front_page() && is_home() ){
// Default homepage
} elseif ( is_front_page()){
//Static homepage
} elseif ( is_home()){
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 | |
/** | |
* Plugin Name: WooCommerce Display Order Count | |
* Plugin URI: http://www.skyverge.com/product/woocommerce-display-order-count/ | |
* Description: Adds the [wc_order_count] shortcode to display the total number of orders placed on your site. | |
* Author: SkyVerge | |
* Author URI: http://www.skyverge.com/ | |
* Version: 1.1.0 | |
* | |
* GitHub Plugin URI: bekarice/woocommerce-display-order-count |
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 | |
/** | |
* Plugin Name: Elementor Scheme Class Issue | |
* | |
* 1) Create wp-content/mu-plugins folder | |
* 2) Create php file (name doesn't matter) | |
* 3) Copy/Paste | |
**/ | |
namespace Elementor; |
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 | |
if (!isset($_GET['ILoveMauticReallyIDo'])) { | |
echo 'The secret phrase is wrong.'; | |
die; | |
} | |
$link = "http://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; | |
$allowedTasks = array( | |
'cache:clear', |
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
Masks Form Fields - WordPress Plugin | |
Link: https://wordpress.org/plugins/masks-form-fields/ |
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 mytheme_add_masvideos_support() { | |
add_theme_support( 'masvideos' ); | |
} | |
add_action( 'after_setup_theme', 'mytheme_add_masvideos_support' ); |
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(document){ | |
function populateForms(){ | |
if (document.readyState == 'interactive') { | |
if (document.forms.length !== 0 && location.search) { | |
var query = location.search.substr(1); | |
query.split('&').forEach(function (part) { | |
if (part.indexOf('=') !== -1) { | |
var item = part.split('='); | |
var key = item[0]; | |
var value = decodeURIComponent(item[1]); |
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 | |
/** | |
* Creates a woocommerce product from a loystar product | |
* | |
* @param int $product_id(optional | |
* @param array $product_list(optional) | the loystar product list, this saves resources incase this function is called in the loop, the | |
* endpoint shouldn't be called everything | |
* @param bool $link_product(optional) | if set to true, the created woocommerce product will be linked to the loystar product | |
* @param bool $update(optional) | if set to true, it updates an existing product | |
* @param bool $only_import(optional) | if set to true, it updates only products that were imported from loystar direct.relevant when $update is 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
<?php | |
/** | |
* Method 1 | |
* Can be used for: Any storage type | |
* | |
* page-slug - replace this with your Option Page slug | |
* option-name - replace this with your option Name/ID | |
*/ | |
$value = jet_engine()->listings->data->get_option( 'page-slug::option-name' ); |
NewerOlder