| Server IP : 159.69.118.108 / Your IP : 216.73.216.200 Web Server : Apache/2.4.58 (Ubuntu) System : Linux ubuntu-4gb-fsn1-1 6.8.0-90-generic #91-Ubuntu SMP PREEMPT_DYNAMIC Tue Nov 18 13:53:54 UTC 2025 aarch64 User : root ( 0) PHP Version : 8.2.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/clients/deborahrobinson.net/wp-content/themes/debbie/ |
Upload File : |
<?php
/*
Template Name: Links
*/
/**
* The template for displaying home page
*
* This is the template that displays all pages by default.
* Please note that this is the WordPress construct of pages and that
* other "pages" on your WordPress site will use a different template.
*
* @package WordPress
* @subpackage Debbie
* @since Debbie 1.0
*/
get_header(); ?>
<!-- post index page: news -->
<!--container-->
<div class="container">
<?php
// Include the page nav.
get_template_part( 'nav-topmenu', 'nav' );
?>
<div class="divider-box"><hr class="line-divider"/></div>
<!-- body-box -->
<div class="body-box">
<!-- article-box -->
<div class="col-md-12">
<div class="news-columns">
<?php
$parent = $post->ID;
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$query_args = array(
'post_type' => 'page',
'posts_per_page' => 20,
'post_parent' => $parent,
'paged' => $paged
);
// create a new instance of WP_Query
$the_query = new WP_Query( $query_args );
?>
<?php if ($the_query->have_posts()) : while ($the_query->have_posts()) : $the_query->the_post(); // run the loop ?>
<?php
$field_url = 'debbie_meta_link_external_url';
$post_id = $post->ID;
$link_url = strip_tags(rwmb_meta( $field_url, $args = array(), $post_id ));
?>
<!-- item -->
<div class="news-item">
<a href="<?php echo $link_url; ?>" class="img-container transparent-onhover" target="_blank">
<?php if (has_post_thumbnail()) { ?>
<?php the_post_thumbnail(array(500, 530), array('class' => 'img-responsive transparent-onhover')); ?>
<?php } else { ?>
<img src="http://placehold.it/500x530" class="img-responsive" alt="<?php the_title(); ?>" />
<?php } ?>
</a>
<div class="news-text-box">
<h3 class="news-title"><a href="<?php echo $link_url; ?>" target="_blank"><?php the_title(); ?></a></h3>
<p class="news-excerpt"><?php the_content(); ?></p>
</div>
</div>
<!-- item -->
<?php endwhile; ?>
<?php
// Reset the post to the original after loop. otherwise the current page becomes the last item from the while loop.
// https://codex.wordpress.org/Function_Reference/wp_reset_query
wp_reset_query();
?>
<?php else :?>
<p>No content found.</p>
<?php endif; ?>
</div>
<!-- columns -->
<?php
// Include the pagination.
include 'pagination.php';
?>
</div>
<!-- article-box -->
</div>
<!-- body-box -->
</div>
<!--container-->
<?php get_footer(); ?>