Skip to content

Instantly share code, notes, and snippets.

@elimn
elimn / functions.php
Created December 2, 2014 22:27
MT | TEC | Tribe Query Debug
<?php
// Checks the URL for the debug parameter
// example.com/event/event-name/?tribe_query_debug=true
function tribe_events_pre_get_posts_dumper ($query) {
$show_debug_info = isset($_GET['tribe_query_debug']) ? $_GET['tribe_query_debug'] : false;
if(($show_debug_info == "true" && $query->is_main_query() === true) || $show_debug_info == "full") {
echo "<h3>&lt;Tribe Events Query&gt;</h3>";
tribe_spit_it_out($query);
@tmtysk
tmtysk / mediarssgen.rb
Created October 15, 2009 08:37
Creating simple "Media RSS (http://video.search.yahoo.com/mrss)" from jpegs in specified directories and uri.
# mediarssgen.rb
# Creating simple "Media RSS (http://video.search.yahoo.com/mrss)"
# from jpegs in specified directories and uri.
#
# Usage: $ ruby mediarssgen.rb <thumbnail_dir> <image_dir> <uri_root>
require 'rubygems'
require 'libxml'
include LibXML