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
function spellerberg_get_next_events_link() { | |
global $wp_query; | |
$nextlink = ''; | |
$paged = get_query_var( 'paged' ); | |
if ( tribe_is_past() ) : | |
if ( $paged > 2 ) : | |
$nextpagenumber = $paged - 1; |
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 | |
global $post; | |
$args = array( | |
'post_type' => 'mca_exhibitions', | |
'posts_per_page' => -1 | |
); | |
$myposts = get_posts( $args ); |
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 | |
function populate_checkbox($form) { | |
if ( $form['id'] != 15 ) : | |
return $form; | |
endif; | |
foreach($form['fields'] as &$field) : |
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 | |
// Curl helper function | |
function curl_get($url) { | |
$curl = curl_init($url); | |
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); | |
curl_setopt($curl, CURLOPT_TIMEOUT, 30); | |
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1); | |
$return = curl_exec($curl); | |
curl_close($curl); |
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
var myScrollTop = 0; | |
jQuery.fn.openLightbox = function() { | |
if (/iPhone|iPad|iPod/i.test(navigator.userAgent)) { | |
myScrollTop = $('body').scrollTop(); | |
var wpadminbar = 0; | |
if ($('#wpadminbar').length != 0) { | |
wpadminbar = $('#wpadminbar').outerHeight(); |
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
// Image Sizes | |
add_image_size( 'padmini', 1024 ); | |
add_image_size( 'phone', 1136 ); | |
add_image_size( 'phoneplus', 1334 ); | |
add_image_size( 'padretina', 2048 ); | |
function spellerberg_get_image($imageid,$fallbacksize = 'full') { | |
$sizes[] = wp_get_attachment_image_src( $imageid, 'padmini'); | |
$sizes[] = wp_get_attachment_image_src( $imageid, 'phone'); |
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 | |
function decoy_page( $query ) { | |
global $wp; | |
if ( !is_admin() && $query->is_main_query() ) { | |
if ( ( $query->get( 'page_id' ) == get_option( 'page_on_front' ) && get_option( 'page_on_front' ) ) || empty( $wp->query_string ) ) { | |
echo 'This displays when set to A Static Page and the homepage is showing.'; |
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: Connections | |
*/ | |
function clock_p2p_register_connections() { | |
p2p_register_connection_type( array( | |
'name' => 'posts_to_tribe_events', |
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
<script type="text/javascript" src="<?php echo get_stylesheet_directory_uri() ?>/map.js"></script> |
OlderNewer