Display 3 different shortcodes for event sections

This commit is contained in:
Brian Miyaji
2014-04-18 22:33:30 +10:00
parent 0384fb7425
commit 16429008a9
6 changed files with 111 additions and 30 deletions

View File

@@ -0,0 +1,24 @@
<?php
/**
* Event Details Shortcode
*
* @author ThemeBoy
* @category Shortcodes
* @package SportsPress/Shortcodes/Event_Details
* @version 0.8
*/
class SP_Shortcode_Event_Details {
/**
* Output the event details shortcode.
*
* @param array $atts
*/
public static function output( $atts ) {
if ( ! isset( $atts['id'] ) && isset( $atts[0] ) && is_numeric( $atts[0] ) )
$atts['id'] = $atts[0];
sp_get_template( 'event-details.php', $atts );
}
}