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
/** | |
* Get the host of the this script. The host will be used for posting the data. | |
*/ | |
var getHost = function () { | |
var scripts = document.getElementsByTagName("script"); | |
var i; | |
for (i = 0; i < scripts.length; i++) { | |
var urlAttribute = scripts[i].attributes.getNamedItem("src"); | |
if (urlAttribute) { | |
var url = urlAttribute.nodeValue; |
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
If you just want to hide the widget form showing in the panel, you can simply set the widget's show_in_panel parameter to false ex: | |
add_filter( 'elementor/editor/localize_settings', function( $settings ) { | |
$settings['widgets']['heading']['show_in_panel'] = false; | |
return $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
global $elementor_widget_blacklist; | |
$elementor_widget_blacklist = [ | |
,'common' | |
,'heading' | |
,'image' | |
,'text-editor' | |
,'video' | |
,'button' | |
,'divider' |
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 basey_scripts_header() { | |
wp_enqueue_script('modernizr', get_template_directory_uri() . '/js/modernizr.foundation.js', '', null, false); | |
} | |
add_action('template_redirect','basey_scripts_header', 8); |
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 | |
add_action( 'wp_enqueue_scripts', 'enqueue_my_styles' ); | |
/** | |
* Example callback function that demonstrates how to properly enqueue conditional stylesheets in WordPress for IE. | |
* IE10 and up does not support conditional comments in standards mode. | |
* | |
* @uses wp_style_add_data() WordPress function to add the conditional data. | |
* @link https://developer.wordpress.org/reference/functions/wp_style_add_data/ |
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
" Make IE Better Compatible " | |
<!--[if IE]> | |
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script> | |
<![endif]--> | |
====================================================== | |
IE6 Only | |
================== | |
_selector {...} |
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_action( 'wp_enqueue_scripts', 'generate_remove_fontawesome', 100 ); | |
function generate_remove_fontawesome() { | |
wp_dequeue_style( 'fontawesome' ); | |
} |
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
{ | |
"$schema": "http://json-schema.org/schema#", | |
"id": "http://advancedcustomfields.com/json-schema/field_group", | |
"type": "object", | |
"definitions": { | |
"empty": { | |
"type": "string", | |
"maxLength": 0 | |
}, | |
"intOrEmpty": { |
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 | |
add_action( 'genesis_meta', 'agency_home_genesis_meta' ); | |
/** | |
* Add widget support for homepage. If no widgets active, display the default loop. | |
* | |
* Link http://wpsites.net/web-design/add-widget-home-php-genesis/ | |
*/ | |
function agency_home_genesis_meta() { |
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
//This code gets added to the end of the home.php file before the genesis() tag. | |
function agency_home_full_helper() { | |
if ( is_active_sidebar( 'full-content' ) ) { | |
echo '<div id="full-content">'; | |
dynamic_sidebar( 'full-content' ); | |
echo '</div><!-- end #full-content -->'; | |
} | |
} |