Date posting on page using template that does not have date post code

This is going to seem like a no-brainer, but I have pages posting a date that should not be posting a date.

The page link above is using the ‘Default Template’. The source code says that it is using the:
<body class="page page-id-253 page-template-default logged-in admin-bar page-faq full-width single-author customize-support">, which tells me it is using the page.php template. The page.php template uses the content-page.php template:

<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part( 'content', 'page' ); ?>

Inside content-page.php, there are no instances of date code.

    <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    <div class="container">
        <div class="entry-header">
            <h1 class="entry-title"><?php the_title(); ?></h1>
        </div>

        <div class="entry-content">
            <?php the_content(); ?>
            
            <!--FAQs content display--> 
                <?php if( get_field('faqs') ): ?>
                            <?php
                                // vars
                                $rows = get_field('faqs');
                                $id = get_sub_field('id');
                                $question = get_sub_field('question');
                                $answer = get_sub_field('answer');
                        ?>
                             
                            <?php if( have_rows('faqs') ): ?>
                    <div class="container">
                          <div class="panel-group" id="accordion">
                             <?php while( have_rows('faqs') ): the_row(); ?>
                               <div class="panel panel-default">                                  
                                  <div class="panel-heading">
                                     <h4 class="panel-title">
                                        <a data-toggle="collapse" data-parent="#<?php the_sub_field('id'); ?>" href="#<?php the_sub_field('id'); ?>">
                                           <?php the_sub_field('question'); ?>
                                        </a>
                                     </h4>
                                  </div>
                                  <div id="<?php the_sub_field('id'); ?>" class="panel-collapse collapse">
                                     <div class="panel-body">
                                        <?php the_sub_field('answer'); ?>
                                     </div>
                                  </div>
                                  
                               </div>
                               
                             <?php endwhile; ?>
                            <?php endif; ?>
                       </div>
                   </div>
                <?php endif; ?><!--end 'faqs' if-->

Now the hierarchy, correct me if I’m wrong, is that whatever <?php get_template_part( is assigned in the page.php template, it should use that content code, right? And if there is no reference to posting the info., it would default to content.php.

With that being said, in content.php, there is no code referring to posting a date. So this makes it more confusing. The only templates that I have posting dates is custom blog templates. And they are not assigned to the page(s) mentioned above.

Can someone give me some clarification where I’m missing the code that is posting the date? Or is this a default setting in WordPress to post dates on the Default Template?

From the look of the code you are processing posts rather than pages for display in the page. The main difference between entries defined as posts and entries defined as pages is that the ones defined as posts allways have a post date associated with them.

The only POSTS there are is the Blog. Everything else is a page.

So if what you’re saying is true, where did I go wrong in creating the template(s)?

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.