Home Forums Support Page.php

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
  • #58238
    Marco Parma

    Hi Tom

    I am having problems with my pages. On the homepage the right sidebar is working fine, but on the other pages the sidebar is coming near the footer. I think i messed up the page.php. Can you have a look please:


    * The template for displaying all pages.
    * 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 Generate

    get_header(); ?>

    <div id=”primary” <?php generate_content_class();?>>
    <main id=”main” <?php generate_main_class(); ?> itemprop=”mainContentOfPage” role=”main”>
    <?php do_action(‘generate_before_main_content’); ?>
    <?php while ( have_posts() ) : the_post(); ?>

    <?php get_template_part( ‘content’, ‘page’ ); ?>

    // If comments are open or we have at least one comment, load up the comment template
    if ( comments_open() || ‘0’ != get_comments_number() ) : ?>
    <div class=”comments-area”>
    <?php comments_template(); ?>
    <?php endif; ?>

    <?php endwhile; // end of the loop. ?>
    <?php do_action(‘generate_after_main_content’); ?>
    </main><!– #main –>
    </div><!– #primary –>



    Marco Parma

    Tom, can you tell me if the page.php is right please?

    I don’t know why the sidebar is not working on the normal pages.

    Lead Developer
    Lead Developer

    Hi Marco,

    Any reason you edited page.php? Try replacing it with the original code: https://themes.svn.wordpress.org/generatepress/1.2.4/page.php

    If that doesn’t work, you probably have an unclosed HTML element within your content.

    This means you may have opened a <div> without closing it (</div>).

    That can cause the layout to go out of whack because it disrupts the flow of the HTML.

    Let me know ๐Ÿ™‚

    Marco Parma

    I replaced the page.php but not working.

    Also on a blank page i have the problem:


    but on error page is working


    I will search for open html or do you have any other idea?

    Lead Developer
    Lead Developer

    Try replacing the content-page.php file with the default file: https://themes.svn.wordpress.org/generatepress/1.2.4/content-page.php

    It looks like you removed the end of a commented phrase after the closing </article>.

    Marco Parma

    Dear Tom

    Thanks a lot. Now is working

    Have a nice day

    Lead Developer
    Lead Developer

    Glad I could help ๐Ÿ™‚

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.