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 | |
| /* ————————————————————————— */ | |
| /* ACF Inline SVGs | |
| /* ————————————————————————— */ | |
| $repeater = 'repeater_field_name' | |
| if ( have_rows( $repeater ) ): ?> | |
| <section class="content-main"> | |
| <div class="container"> <?php |
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
| <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> | |
| <script src="https://cdn.jsdelivr.net/jquery.validation/1.16.0/jquery.validate.min.js"></script> | |
| <script src="https://cdn.jsdelivr.net/jquery.validation/1.16.0/additional-methods.min.js"></script> | |
| <form id="myForm" name="myForm" action="#" method="POST"> <style>#email-error { display: block; color: red; }</style> | |
| <label for="email">Email: </label> | |
| <input id="email" name="email" type="email" minlength="6"/><br> | |
| <input type="submit" value="Submit"> | |
| </form> |
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
| # http://inlinedocs.gravityhelp.com/class-GFAPI.html | |
| # https://docs.gravityforms.com/getting-started-with-the-gravity-forms-api-gfapi/ | |
| # working code | |
| # notes: we are to going to lists submitted entries of the current loggedin user. | |
| $form_ids = [19, 20, 21, 22, 23, 24, 25, 26]; // accepts single or array of form id's. | |
| $search_criteria = array( | |
| 'field_filters' => array( | |
| 'mode' => 'any', |
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 | |
| /** adds a scroll handler to turn load more into a infinite scroll **/ | |
| add_action( 'wp_footer', function() { | |
| ?> | |
| <script> | |
| (function($) { | |
| if ('object' !== typeof FWP) { | |
| return; |
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 | |
| /* Pull apart OEmbed video link to get thumbnails out*/ | |
| function get_video_thumbnail_uri( $video_uri ) { | |
| $thumbnail_uri = ''; | |
| // determine the type of video and the video id | |
| $video = parse_video_uri( $video_uri ); | |
| // get youtube thumbnail |
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
| UPDATE wp_options SET option_value = replace(option_value, 'http://www.oldurl', 'http://www.newurl') WHERE option_name = 'home' OR option_name = 'siteurl'; | |
| UPDATE wp_posts SET guid = replace(guid, 'http://www.oldurl','http://www.newurl'); | |
| UPDATE wp_posts SET post_content = replace(post_content, 'http://www.oldurl', 'http://www.newurl'); | |
| UPDATE wp_postmeta SET meta_value = replace(meta_value,'http://www.oldurl','http://www.newurl'); |
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
| { | |
| "name": "gp-sage-foundation", | |
| "homepage": "https://grindpress.com", | |
| "authors": [ | |
| "Shaun Burrell <shaun@grindpress.com>" | |
| ], | |
| "license": "MIT", | |
| "private": true, | |
| "dependencies": { | |
| "foundation-sites": "^6.4.3" |
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
| # /wp-content/uploads/.htaccess | |
| RewriteEngine On | |
| RewriteCond %{REQUEST_FILENAME} !-f | |
| RewriteRule (.*) http://www.yourproductionserver.com/wp-content/uploads/$1 [L] |
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
| /* | |
| * CSS3 triangle Mixin | |
| * @param {Direction} $direction - Triangle direction, either `top`, `right`, `bottom` or `left` | |
| * @param {Color} $color - Triangle color | |
| * @param {Length} $size [1em] - Triangle size | |
| * | |
| * Useage - @include triangle(#000,1em,right); | |
| * place in the parent element | |
| * https://css-tricks.com/snippets/css/css-triangle/ | |
| * |