HEX
Server: Apache
System: Linux p3plzcpnl489499.prod.phx3.secureserver.net 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
User: dwauav0tm6jp (6177017)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: /home/dwauav0tm6jp/hosted/jeffreyjhart_com/wp-content/themes/skylab/content-gallery.php
<?php
/**
 * The template for displaying posts in the Gallery Post Format
 *
 * @package WordPress
 * @subpackage Skylab
 * @since Skylab 1.0
 */
?>
	
	<article id="post-<?php the_ID(); ?>" <?php post_class('clearfix'); ?>>
	
		<?php								
					global $post;

					if ( metadata_exists( 'post', $post->ID, '_post_image_gallery' ) ) {
						$page_image_gallery = get_post_meta( $post->ID, '_post_image_gallery', true );
					} else {
						// Backwards compat
						$attachment_ids = array_filter( array_diff( get_posts( 'post_parent=' . $post->ID . '&numberposts=-1&post_type=attachment&orderby=menu_order&order=ASC&post_mime_type=image&fields=ids' ), array( get_post_thumbnail_id() ) ) );
						$page_image_gallery = implode( ',', $attachment_ids );
					}
								
					$attachments = array_filter( explode( ',', $page_image_gallery ) );
					$thumbs = array();
					if ( $attachments ) { ?>
						<div class="post-gallery-slider royalSlider rsMinW clearfix">
							<?php foreach ( $attachments as $attachment_id ) { ?>
								<?php $gallery_image_src = wp_get_attachment_image_src( $attachment_id, 'full' ); ?>
								<?php $gallery_image_thumb = wp_get_attachment_image_src( $attachment_id, 'thumbnail' ); ?>
								<?php $attachment = get_post( $attachment_id ); ?>
								<?php $attachment_title = apply_filters( 'the_title', $attachment->post_title ); ?>
								<img class="rsImg" src="<?php echo $gallery_image_src[0]; ?>" width="<?php echo $gallery_image_src[1]; ?>" height="<?php echo $gallery_image_src[2]; ?>" alt="<?php echo $attachment_title; ?>" data-rsTmb="<?php echo $gallery_image_thumb[0]; ?>" />
							<?php } ?>
						</div><!-- #post-gallery-slider -->
									
					<?php } else { ?>
						<p class="no-found"><?php _e( 'No images found, please add some images.', 'mega' ); ?></p>
					<?php } // end if ( $attachments ) ?>
		
		<div class="entry-content-meta-wrapper">
		<header class="entry-header">
			<?php if ( 'post' == get_post_type() ) : ?>
				<div class="entry-meta">
					<?php $show_sep = false; ?>
					<?php
						/* translators: used between list items, there is a space after the comma */
						$categories_list = get_the_category_list( __( ', ', 'mega' ) );
						if ( $categories_list ):
					?>
					<span class="cat-links">
						<?php printf( __( '<span class="%1$s"></span> %2$s', 'mega' ), 'entry-utility-prep entry-utility-prep-cat-links', $categories_list );
						$show_sep = true; ?>
					</span>
					<span class="sep">|</span>
					<?php endif; // End if categories ?>

					<?php mega_posted_on(); ?>
				</div><!-- .entry-meta -->
			<?php endif; ?>
			<h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permanent Link to %s', 'mega' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
		</header><!-- .entry-header -->
		
			<div class="entry-content clearfix">
				<?php the_content( __( 'Read more <span class="meta-nav">&rarr;</span>', 'mega' ) ); ?>
				<?php wp_link_pages( array( 'before' => '<div class="page-link"><span>' . __( 'Pages:', 'mega' ) . '</span>', 'after' => '</div>' ) ); ?>
			</div><!-- .entry-content -->
				
			<footer class="entry-meta">
		
				<?php $show_sep = false; ?>
				<?php if ( 'post' == get_post_type() ) : // Hide category and tag text for pages on Search ?>
				<?php
					/* translators: used between list items, there is a space after the comma */
					$tags_list = get_the_tag_list( '', __( ', ', 'mega' ) );
					if ( $tags_list ):
					if ( $show_sep ) : ?>
				<span class="sep"> | </span>
					<?php endif; // End if $show_sep ?>
				<span class="tag-links">
					<?php printf( __( '<span class="%1$s"><i class="fontello-tag"></i></span> %2$s', 'mega' ), 'entry-utility-prep entry-utility-prep-tag-links', $tags_list );
					$show_sep = true; ?>
				</span>
				<?php endif; // End if $tags_list ?>
				<?php endif; // End if 'post' == get_post_type() ?>

				<?php if ( comments_open() ) : ?>
				<?php if ( $show_sep ) : ?>
				<span class="sep"> | </span>
				<?php endif; // End if $show_sep ?>
				<span class="comments-link"><?php comments_popup_link( ''. __( '<i class="fontello-comment"></i> Comment', 'mega' ) .'', __( '<i class="fontello-comment"></i> <b>1</b> Comment', 'mega' ), __( '<i class="fontello-comment"></i> <b>%</b> Comments', 'mega' ) ); ?></span>
				<?php endif; // End if comments_open() ?>

				<?php $sep = '<span class="sep"> | </span>' ?>
				<?php edit_post_link( __( '<i class="fontello-pencil"></i> Edit', 'mega' ), '' . $sep . '<span class="edit-link">', '</span>' ); ?>
				
				<?php if ( !is_single() ) : // Checks if any single post is being displayed ?>
					<?php $the_title = get_the_title(); ?>
					<?php $url = get_permalink(); ?>
					<?php do_action( 'addthis_widget', $url, $the_title, 'simple_button' );?>
				<?php endif; // End if ( !is_single() ) ?>
			</footer><!-- #entry-meta -->
			</div><!-- .entry-content-meta-wrapper -->
		
			<?php if ( is_single() ) : // Checks if any single post is being displayed ?>
				<nav id="nav-single">
					<h3 class="assistive-text"><?php _e( 'Post navigation', 'mega' ); ?></h3>
					<span class="nav-previous"><?php previous_post_link( '%link', __( 'Older <i class="icon-chevron-right"></i>', 'mega' ) ); ?></span>
					<span class="nav-next"><?php next_post_link( '%link', __( '<i class="icon-chevron-left"></i> Newer', 'mega' ) ); ?></span>
				</nav><!-- #nav-single -->
			
			<?php comments_template( '', true ); ?>
			<?php endif; // End if ( is_single() ) ?>
		
	</article><!-- #post-<?php the_ID(); ?> -->