Skip to content

Instantly share code, notes, and snippets.

@SchneiderSam
SchneiderSam / gp-mega-menu.php
Last active May 25, 2024 15:14 — forked from diggeddy/gp-mega-menu.php
Create a sub menu item container with action hook (Mega Menu with GeneratePress and GenerateBlocks)
<?php
add_filter( 'walker_nav_menu_start_el', 'db_sub_menu_item_hook', 10, 4 );
function db_sub_menu_item_hook( $item_output, $item, $depth, $args ) {
// Specify menu item class to target
$class_string = 'gp_mega_item';
$menu_item_classes = $item->classes;
if ( empty( $menu_item_classes ) || !in_array( $class_string , $menu_item_classes ) ) {
return $item_output;
@humbertosilva
humbertosilva / vc_infinite_image_carousel.txt
Last active July 5, 2021 10:07
Turn Visual Composer Image Carousel into Visual Composer INFINTE Image Carousel
@haroldparis
haroldparis / force_wp_title_for_yoast.php
Last active December 19, 2018 11:10
WooCommerce : Forcing to use wp_title() over woo_title() for WordPress SEO by Yoast
<?php
// Forcing to use wp_title() for WordPress SEO by Yoast ... damn.
function force_wp_title_for_yoast() {
return wp_title();
}
add_filter( 'woo_title', 'force_wp_title_for_yoast' );
?>
@return1
return1 / trim_enabler.txt
Last active May 26, 2024 11:01
TRIM Enabler for OS X Yosemite 10.10.3
#
# UPDATE for 10.10.4+: please consider this patch obsolete, as apple provides a tool called "trimforce" to enable trim support for 3rd party SSDs
# just run "sudo trimforce enable" to activate the trim support from now on!
#
# Original version by Grant Parnell is offline (http://digitaldj.net/2011/07/21/trim-enabler-for-lion/)
# Update July 2014: no longer offline, see https://digitaldj.net/blog/2011/11/17/trim-enabler-for-os-x-lion-mountain-lion-mavericks/
#
# Looks for "Apple" string in HD kext, changes it to a wildcard match for anything
#
# Alternative to http://www.groths.org/trim-enabler-3-0-released/
@malarkey
malarkey / Contract Killer 3.md
Last active May 24, 2024 23:38
The latest version of my ‘killer contract’ for web designers and developers

When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.

Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008

…………………………