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: Envira CDN Fix | |
* Plugin URI: https://logoscreative.com | |
* Description: Support images on a CDN with Envira | |
* Version: 1.0 | |
* Author: Logos Creative | |
* Author URI: https://logoscreative.com | |
*/ |
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 | |
/** | |
* Genesis + ECP Handshake | |
* | |
* Integrates the things from: https://theeventscalendar.com/knowledgebase/genesis-theme-framework-integration/ | |
* | |
* @package genesis_ecp_handshake | |
* @author Cliff Seal <[email protected]> | |
* @link http://evermo.re | |
* @copyright 2015 Logos Creative |
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
/** | |
* NOTE: Unencode > in DPP Freeform CSS | |
* | |
* @since 1.0.9 | |
*/ | |
function evermore_unencode_dpp_css( $safe_text, $text ) { | |
if ( strpos( $safe_text, 'gt;' ) !== false && strpos( $safe_text, 'lt;' ) === false ) { | |
$safe_text = $text; |
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 | |
/** | |
* Batch Set External Images in Content as Featured Images | |
* | |
* Look for external images shoved into the content, upload them to the Media Library, and assign it as the featured post. | |
* | |
* @package batch_upload_featured | |
* @author Cliff Seal <[email protected]> | |
* @link http://evermo.re | |
* @copyright 2015 Logos Creative |
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 | |
/** | |
* WordPress stores all meta fields as strings, which causes problems for ordering by numbers. When using Pods::find() directly, this issue can be addressed by casting the field as a decimal, as shown here: https://github.com/pods-framework/pods-code-library/blob/master/example/classes/Pods/find/examples/orderby-number.php | |
* | |
* In shortcodes, this strategy is not possible, as MySQL functions can not be used in the WordPress post editor. Instead, you can use the "pods_shortcode_findrecords_params" params filter, as shown below: | |
*/ | |
/** | |
* Example to order by a price field properly. | |
*/ |
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
{ | |
"1":{ | |
"psalm-1":"Ps. 103", | |
"psalm-2":"Ps. 148", | |
"ot":"Isa. 62:1-5,10-12", | |
"nt":"Rev. 19:11-16", | |
"gospel":"Matt. 1:18-25" | |
}, | |
"2":{ | |
"psalm-1":"Ps. 34", |
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 | |
/** | |
* "Friendlier, Safer WordPress Admin Areas" | |
* Presented by Cliff Seal at WordCamp Atlanta 2015 and Asheville 2016 | |
* Slides: http://www.slideshare.net/cliffseal/wp-admin | |
* | |
* Plugin Name: A Better Admin Experience | |
* Plugin URI: http://evermoresites.com | |
* Description: Cleans up and sanitizes the WordPress admin area | |
* Version: 1.0 |
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
/* Make Events Form Work Redux */ | |
add_filter("gform_post_data", "mb_set_post_date", 10, 3); | |
function mb_set_post_date($post_data, $form, $entry){ | |
if($form["id"] != 48) | |
return $post_data; | |
$startdate = $entry["69"]; | |
$starttime = $entry["5"]; |
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 | |
/** | |
* Finds the the full filepath for /wp-load.php in a ancestor directory. | |
* | |
* Walks up the parent directory stack to locate wp-load.php. | |
* Used by files in plugins that need require() wp-load.php | |
* but that might not be stored exactly where expected. | |
* | |
* Works as long as the wp-load.php is found by traversing parent directories. | |
* |
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
if( !empty($get_recurrence_event->posts) && tribe_is_recurring_event($get_recurrence_event->posts[0]->ID) && get_post_status($get_recurrence_event->posts[0]) == 'publish' ){ | |
$nextevent = ''; | |
$now = strtotime('now'); | |
foreach ( tribe_get_recurrence_start_dates($event->ID) as $eventinstance ) { | |
$upcoming = strtotime($eventinstance); | |
if ( $now < $upcoming ) { | |
$eventinstance = explode(" ", $eventinstance); | |
$nextevent = $eventinstance[0]; | |
break; | |
} |
NewerOlder