function sunshine_content($content) { global $post, $wp_query, $sunshine; if (!is_sunshine()) { return $content; } if (isset($_GET['sunshine_search'])) { $content = self::get_template('search-results'); } elseif (isset(self::$current_image)) { if (post_password_required(self::$current_gallery)) { $content = get_the_password_form(); } else { $content = self::get_template('image'); } } elseif (isset(self::$current_gallery)) { if (post_password_required(self::$current_gallery)) { $content = get_the_password_form(); } elseif (!current_user_can('sunshine_manage_options') && sunshine_gallery_requires_email(self::$current_gallery->ID)) { $content = sunshine_gallery_email_form(); } else { $content = self::get_template('gallery'); } } elseif (isset(self::$current_order)) { $content = self::get_template('order'); } elseif (is_page($sunshine->options['page'])) { $content = $content . self::get_template('home'); } elseif (is_page($sunshine->options['page_cart'])) { $content = $content . self::get_template('cart'); } elseif (is_page($sunshine->options['page_checkout'])) { $content = $content . self::get_template('checkout'); } elseif (is_page($sunshine->options['page_account'])) { $content = $content . self::get_template('account'); } return apply_filters('sunshine_content', $content); }
<?php sunshine_action_menu(); ?> </div> <?php $this_gallery_id = $post->ID; $child_galleries = sunshine_get_child_galleries(); ?> <div id="sunshine-gallery-images" class="sunshine-clearfix"> <?php if (!sunshine_is_gallery_expired()) { if (post_password_required(SunshineFrontend::$current_gallery)) { echo get_the_password_form(); } elseif (sunshine_gallery_requires_email(SunshineFrontend::$current_gallery->ID)) { echo sunshine_gallery_email_form(); } else { sunshine_gallery_expiration_notice(); if (SunshineFrontend::$current_gallery->post_content) { ?> <div id="sunshine-content"> <?php echo apply_filters('the_content', SunshineFrontend::$current_gallery->post_content); ?> </div> <?php } if ($child_galleries->have_posts()) { ?> <div id="sunshine-gallery-list" class="sunshine-clearfix"> <ul class="sunshine-col-<?php