Skip to content

Instantly share code, notes, and snippets.

View wpfangirl's full-sized avatar

Sallie Goetsch wpfangirl

View GitHub Profile
<?php
/**
* Associate an uploaded file with a post on form submission in Gravity Forms
*
* This is specific to a comment on my post about connecting GF with ACF
*
* @see https://joshuadnelson.com/connect-gravity-forms-file-upload-to-acf-gallery-field/#comment-13186
* @author Joshua David Nelson, josh@joshuadnelson.com
*/
$gravity_form_id = 1; // gravity form id, or replace {$gravity_form_id} below with this number
@GeoffEW
GeoffEW / prevent_export.php
Last active October 2, 2022 15:15
Prevent calendar export links from showing anywhere on the front-end.
<?php
/**
* Prevent calendar export links from showing anywhere on the front-end.
*
*
*/
class Tribe__Events__Remove__Export__Links {
public function __construct() {
add_action( 'init', array( $this, 'single_event_links' ) );
@jchristopher
jchristopher / gist:7312074
Last active August 12, 2020 02:43
Supplemental SearchWP search engine integration with Genesis, supports pagination
<?php
/* Template Name: Genesis and SearchWP integration with pagination */
function prefix_searchwp_form( $query ) {
echo '<form class="searchwp-form" action="" method="get">';
echo '<input type="text" id="searchwpquery" name="searchwpquery" value="' . esc_attr( $query ) . '" />';
echo '<button type="submit">' . __( 'Search', 'text-domain' ) . '</button>';
echo '</form>';
}
@hucklesby
hucklesby / dabblet.css
Created October 18, 2013 23:02
Fit caption to the width of any image
/**
* Fit caption to the width of any image
*/
.captioned-figure {
display: table;
table-layout: fixed;
}
.captioned-figure img {
margin-bottom: 10px;
border: 0;