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 wp_dropdown_categories( array('taxonomy' => TribeEvents::TAXONOMY) ); ?> |
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 /* Template Name: Home */ ?> | |
<?php get_header(); ?> | |
<?php // echo adrotate_group(1); ?> | |
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> | |
<div class="left"> | |
<?php the_content() ?> | |
</div> | |
<div class="main-image"><?php the_post_thumbnail( 'full' ); ?></div> |
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 | |
/** | |
* This is an example of a query which gets a single random event from the | |
* 'featured' event category amongsts evetns from The Events Calendar | |
* | |
* @see http://tri.be/support/forums/topic/random-featured-event-custom-widget/ | |
*/ | |
get_header(); |
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 | |
/** | |
* Filter the iCal link generated by The Events Calendar Pro to use the webcal | |
* protocal instead of http | |
* | |
* Note: if you have https:// on your site, pelase adjust accordingly | |
* | |
* @author jkudish | |
* @param string $link the original | |
* @return string $link the filtered link |
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 | |
$i = 0; | |
$max_iterations = 300; | |
$string_to_copy = 'your string'; | |
while ($i =< $max_iterations) { | |
echo $string_to_copy; | |
echo '<br><br>'; // just to have some space between each iteration | |
$i++; | |
} |
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 | |
/** | |
* Filters the year dropdown in The Events Calendar plugin's grid view | |
* shows the current year isntead of the last 2 | |
* | |
* @author Joachim Kudish @link http://jkudish.com | |
* @version 1.0 | |
* @param (string) $yearOptions the number of years options string | |
* @return (string) $yearOptions the filtered number of years options string | |
*/ |
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 date_default_timezone_set('America/New_York'); ?> |
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 | |
global $post; | |
$get_posts = tribe_get_events(array('posts_per_page'=>10, 'venue'=>176) ); | |
foreach($get_posts as $post) { setup_postdata($post); ?> | |
<div class="post"> | |
<h4 class="post-header"><a href="<?php the_permalink(); ?>" id="post-<?php the_ID(); ?>"><?php the_title(); ?></a></h4> | |
<span class="event-date"><a href="<?php the_permalink(); ?>"><?php echo tribe_get_start_date($post->ID, true, 'M j, Y'); ?></a></span> | |
<div class="post-content"><?php the_content(); ?></div> |
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 | |
/* | |
Plugin Name: Logged in only events calendar | |
Plugin URI: http://tri.be/support/forums/topic/calendar-view/#post-14059 | |
Description: Prevents non-loggedin users from seing The Events Calendar. Requires The Events Calendar by Modern Tribe Inc | |
Version: 0.1 | |
Author: Joachim Kudish | |
Author URI: http://jkudish.com/ | |
License: GPLv2 |
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 | |
/** | |
* keeps a user always logged in | |
* don't use this on a production site, ever! | |
*/ | |
add_action('init', 'auto_login'); | |
add_action('admin_init', 'auto_login'); | |
function auto_login() { |