default_layout(); break; } // End of $layout switch } // End of get_layout() /** * Displays the ArtistData XML feed for use on a page * * Gets all the plugins options, gets the XML data as an array, * then outputs an HTML table based on the user-selected options. * * @since 0.4 * * @return mixed $output HTML-formatted table showing upcoming shows from an ArtistData feed */ function default_layout() { $options = get_option( 'slushman_adp_options' ); $showfeed = $this->get_xml(); extract( $options ); if ( $slushman_adp_shows_artist == 'on' ) { } ?>
show as $show ) { // Date if ( $slushman_adp_date_format == 'default' ) { $date_format = get_option( 'date_format' ); } else { $date_format = $slushman_adp_date_format; } // End of $slushman_adp_date_format check $showdate = strtotime( $show->date ); $date = date( $date_format, $showdate ); // Time if ( $slushman_adp_time_format == 'default' ) { $time_format = get_option( 'time_format' ); } else { $time_format = $slushman_adp_time_format; } // End of $slushman_adp_time_format check $showtime = strtotime( $show->timeSet ); $time = date( $time_format, $showtime ); // ISO if ( $show->showtimeZone != 'System/Localtime' ) { $convert = new DateTime( $show->date . ' ' . $show->timeSet, new DateTimeZone( $show->showtimeZone ) ); $iso = $convert->format( DATE_ATOM ); } else { // get diff between GMT time and show time $atom = $show->date . 'T' . substr( $show->timeSet, 0, 12 ); $difftemp = strtotime( $show->gmtDate ) - strtotime( $atom ); $hours = $difftemp / 60 / 60; $hour = $hours < 9 ? '0' . $hours : $hours; $diff = $hour . ':00'; $porm = $diff > 0 ? '-' : '+'; $iso = $show->date . 'T' . substr( $show->timeSet, 0, 12 ) . $porm . $diff; } // End of time zone check // Venue // Make the venue name a link to their site, else display venue name if ( $show->venueURI && $show->venueURI != '' ) { $venue = '' . $show->venueName . ''; } else { $venue = '' . $show->venueName . ''; } // End of $show->venueURI empty check // Location if ( $show->stateAbbreviation == 'No State' ) { $loc = '' . $show->city . ', ' . $show->country . ''; } elseif ( $slushman_adp_country == 'on' ) { $loc = '' . $show->city . ', ' . $show->stateAbbreviation . ', ' . $show->countryAbbreviation . ''; } else { $loc = '' . $show->city . ', ' . $show->stateAbbreviation . ''; } // End of stateAbbreviation check // Make the city & state a Google Map link, else just show city & state if ( $show->venueAddress && $show->venueAddress != '' ) { // $latitude = ; // $longitude = ; $location = '' . $loc . ' - map '; } else { $location = '' . $loc . ''; } // End of if ( !empty( $show->venueAddress ) ) ?>
at
name; ?>
ticketURI && $show->ticketURI != '' ) { ?> Tickets: ticketPrice; ?> Tickets: ticketPrice; ?>ticketURI empty check } // End of $slushman_adp_display_tickets check // Display the age limit if selected in the plugin options if ( $slushman_adp_display_age == 'on' ) { ?> Age Limit: ageLimit; ?>
 
get_xml(); extract( $options ); ?>
show as $show ) { // Date if ( $slushman_adp_date_format == 'default' ) { $date_format = get_option( 'date_format' ); } else { $date_format = $slushman_adp_date_format; } // End of $slushman_adp_date_format check $showdate = strtotime( $show->date ); $date = date( $date_format, $showdate ); // Time if ( $slushman_adp_time_format == 'default' ) { $time_format = get_option( 'time_format' ); } else { $time_format = $slushman_adp_time_format; } // End of $slushman_adp_time_format check $showtime = strtotime( $show->timeSet ); $time = date( $time_format, $showtime ); // ISO $convert = new DateTime( $show->date . ' ' . $show->timeSet, new DateTimeZone( $show->showtimeZone ) ); $iso = $convert->format( 'Y-m-d\TH:i:sP' ); // Venue // Make the venue name a link to their site, else display venue name if ( $show->venueURI && $show->venueURI != '' ) { $venue = '' . $show->venueName . ''; } else { $venue = '' . $show->venueName . ''; } // End of $show->venueURI empty check // Location if ( $show->stateAbbreviation == 'No State' ) { $loc = '' . $show->city . ', ' . $show->country . ''; } elseif ( $slushman_adp_country == 'on' ) { $loc = '' . $show->city . ', ' . $show->stateAbbreviation . ', ' . $show->countryAbbreviation . ''; } else { $loc = '' . $show->city . ', ' . $show->stateAbbreviation . ''; } // End of stateAbbreviation check // Make the city & state a Google Map link, else just show city & state if ( $show->venueAddress && $show->venueAddress != '' ) { // $latitude = ; // $longitude = ; $location = '' . $loc . ' - map '; } else { $location = '' . $loc . ''; } // End of if ( !empty( $show->venueAddress ) ) ?>
at
name; ?>
ticketURI && $show->ticketURI != '' ) { ?> Tickets: ticketPrice; ?> Tickets: ticketPrice; ?>ticketURI empty check } // End of $slushman_adp_display_tickets check // Display the age limit if selected in the plugin options if ( $slushman_adp_display_age == 'on' ) { ?> Age Limit: ageLimit; ?>