Enough people loved this gist, so it's now a Github repository!
⭐ Please use the "The Events Calendar Reset" on Github going forward. ⭐
// this file is a part of learning process so this file will be changed as I learn stuff :) | |
const iconAttributes = { | |
iconLocation: 'right', | |
columnGap: '0.5em', | |
iconSize: 0.8, | |
iconPaddingRight: '', | |
display: 'flex', | |
alignItems: 'center', | |
justifyContent: 'space-between', | |
sizing: { width: '100%' }, |
Enough people loved this gist, so it's now a Github repository!
⭐ Please use the "The Events Calendar Reset" on Github going forward. ⭐
<?php | |
/** | |
* AMP Gravity Forms Submission Shim plugin bootstrap. | |
* | |
* @package Google\AMP_Gravity_Forms_Submission_Shim | |
* @author Weston Ruter, Google | |
* @license GPL-2.0-or-later | |
* @copyright 2020 Google Inc. | |
* | |
* @wordpress-plugin |
/* | |
This JS creates collapsible Gravity Form sections breaks | |
IMPORTANT: | |
1 - Within the Gravity form, you must add the class collapsible to each section break. | |
2 - All fields within those section breaks must have the class collapsible_field | |
3 - You must include both the CSS and the JS |
<?php | |
/** | |
* Add body class for GravityView contexts | |
*/ | |
add_filter('body_class', function( $classes = array() ) { | |
if ( ! class_exists( '\GV\View_Collection' ) ) { | |
return $classes; | |
} |
<?php | |
// CREDIT: http://pastebin.com/Ju78M8Ax | |
// exclude field from {all_fields} merge tag by adding | |
// :exclude to merge tag | |
add_filter( 'gform_merge_tag_filter', 'exclude_from_all_fields', 10, 4 ); | |
function exclude_from_all_fields ( $value, $merge_tag, $options, $field ) { | |
$options_array = explode ( ",", $options ); | |
$exclude = in_array ( "exclude", $options_array ); | |
// if a field has the CSS Class Name gf_exclude the field will be excluded from the {all_fields:exclude} merge tag |
<?php | |
/** | |
* Gravity Wiz // Gravity Forms // Advanced Conditional Logic | |
* | |
* PLEASE NOTE: This snippet is a proof-of-concept. It is not supported and we have no plans to improve it. | |
* | |
* Allows multiple groups of conditional logic per field. | |
* | |
* @version 0.1 | |
* @author David Smith <[email protected]> |
<?php | |
/* | |
Plugin Name: PHP Compatibility Custom Timeout | |
*/ | |
function custom_timeout( $timeout ) { | |
return 0; | |
} | |
add_filter( 'wpephpcompat_scan_timeout', 'custom_timeout', 10 ); |
## LEVERAGE BROWSER CACHING ## | |
## https://gtmetrix.com/leverage-browser-caching.html ## | |
<IfModule mod_expires.c> | |
ExpiresActive On | |
ExpiresByType image/jpg "access plus 1 year" | |
ExpiresByType image/jpeg "access plus 1 year" | |
ExpiresByType image/gif "access plus 1 year" | |
ExpiresByType image/png "access plus 1 year" | |
ExpiresByType text/css "access plus 1 month" | |
ExpiresByType application/pdf "access plus 1 month" |