HEX
Server: Apache
System: Linux c119.dattaweb.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: c1190199 (57165)
PHP: 7.4.33
Disabled: mail, system, shell, exec, system_exec, shell_exec, mysql_pconnect, passthru, popen, proc_open, proc_close, proc_nice, proc_terminate, proc_get_status, escapeshellarg, escapeshellcmd, eval, dl, imap_mail, libvirt_connect, gnupg_init, unsetenv, apache_setenv, pcntl_exec, pcntl_alarm, pcntl_fork, pcntl_waitpid, pcntl_wait, pcntl_wifexited, pcntl_wifstopped, pcntl_wifsignaled, pcntl_wifcontinued, pcntl_wexitstatus, pcntl_wtermsig, pcntl_wstopsig, pcntl_signal, pcntl_signal_get_handler, pcntl_signal_dispatch, pcntl_get_last_error, pcntl_strerror, pcntl_sigprocmask, pcntl_sigwaitinfo, pcntl_sigtimedwait, pcntl_getpriority, pcntl_setpriority, pcntl_async_signals, opcache_get_status, opcache_reset, opcache_get_configuration
Upload Files
File: /home/c1190199/public_html/wp-content/wptouch-data/themes/classic-redux/default/attachment.php
<?php get_header(); ?>

<div id="content">

	<div class="<?php wptouch_post_classes(); ?> box">

		<?php wptouch_the_post(); ?>

		<?php if ( $post->post_parent > 0 ) {
			echo '<a id="gallery_back_to_post" href="' . get_permalink( $post->post_parent ) . '">' . sprintf( __( 'Back to %s', 'wptouch-pro' ), get_the_title( $post->post_parent ) ) . '</a>';
		} ?>

		<?php
			$attachments = array_values( get_children( array( 'post_parent' => $post->post_parent, 'post_status' => 'inherit', 'post_type' => 'attachment', 'post_mime_type' => 'image', 'order' => 'ASC', 'orderby' => 'menu_order ID' ) ) );
			foreach ( $attachments as $k => $attachment ) {
				if ( $attachment->ID == $post->ID ){
					break;
				}
			}

			$k++;

			if ( count( $attachments ) > 1 ) {
				if ( isset( $attachments[ $k ] ) ) {
					// get the URL of the next image attachment
					$next_attachment_url = get_attachment_link( $attachments[ $k ]->ID );
				} else {
					// or get the URL of the first image attachment
					$next_attachment_url = get_attachment_link( $attachments[ 0 ]->ID );
				}
			} else {
				// or, if there's only 1 image, get the URL of the image
				$next_attachment_url = wp_get_attachment_url();
		}?>

		<a href="<?php echo esc_url( $next_attachment_url ); ?>" title="<?php echo esc_attr( get_the_title() ); ?>" rel="attachment">
			<?php echo wp_get_attachment_image( $post->ID, array( 800, 800 ) ); ?>
		</a>

		<?php if ( !empty( $post->post_excerpt ) ) { ?>
			<div class="entry-caption">
				<?php wptouch_the_excerpt(); ?>
			</div>
		<?php } ?>

		<div class="gallery-nav" role="menu">
			<span class="left" role="menuitem"><?php previous_image_link( false, __( '&laquo; previous in gallery' , 'wptouch-pro' ) ); ?></span>
			&nbsp;
			<span class="right" role="menuitem"><?php next_image_link( false, __( 'next in gallery &raquo;' , 'wptouch-pro' ) ); ?></span>
		</div>

	</div><!-- .post -->

</div><!-- #content -->

<?php get_footer(); ?>