WordPress.org

Ready to get started?Download WordPress

Forums

Jetpack by WordPress.com
[resolved] Jetpack Inifinite Scroll error in unaltered twenty twelve child theme (5 posts)

  1. tcgrafing
    Member
    Posted 1 year ago #

    I have created an unmodified child theme of twenty twelve and wanted to activate jetpack infinite scroll in that child theme.

    However, as you can see on http://www.tcgrafing.de/aktuell/, when you scroll down a bit, the infinite scroll hovering footer does not have the correct width and if you scroll down a few pages, you'll see an "Older Posts" link appearing above one of the articles.

    I can also send screenshots to anyone intersted.

    Does anyone know why is this happening or how to investigate this error? If I activate jetpack infinite scroll in the parent theme twenty twelve, everything works fine.

    Here is my style.css of the child theme

    /*
    Theme Name: Twentytwelve Child Test
    Description: Test Child theme for the twentytwelve theme
    Author: me
    Template: twentytwelve
    */
    
    @import url("../twentytwelve/style.css");

    and here is my functions.php

    <?php
    
    function twenty_twelve_infinite_scroll_init() {
    	add_theme_support( 'infinite-scroll', array(
    		'container'      => 'content'
    	) );
    }
    add_action( 'after_setup_theme', 'twenty_twelve_infinite_scroll_init' );

    Thank you in advance for your help.

    http://wordpress.org/extend/plugins/jetpack/

  2. designsimply
    Member
    Plugin Contributor

    Posted 1 year ago #

    Jetpack 2.0.1 will be updated to have better support for Infinite Scroll for child themes if the parent theme has it already. So, after 2.0.1, you will not need any extra modifications in your Twenty Twelve child theme to make infinite scroll work because Twenty Twelve comes with infinite scroll support built in already.

  3. tcgrafing
    Member
    Posted 1 year ago #

    Hi designsimply, thank you again for your answer, this was exactly the kind of reply I was looking for.

  4. OperaManiac
    Member
    Posted 1 year ago #

    i am not sure if my problem is related but infinite scroll does not work on latest twenty twelve theme unmodified on my blog. even disabling it does not work. i read the document detailing it which states that the theme supports infinite scroll out of the box. i even tried adding the code mentioned in that article to the functions file. no use.

    the end result is, navigation option does not work. even third party plugins do not work to bring back page numbers in the footer.

  5. designsimply
    Member
    Plugin Contributor

    Posted 1 year ago #

    i even tried adding the code mentioned in that article to the functions file. no use.

    Sorry for the confusion on that point! You should *not* add any extra code for infinite scroll to your child theme if you are using Jetpack 2.0.1 or later.

    the end result is, navigation option does not work. even third party plugins do not work to bring back page numbers in the footer.

    @OperaManiac, do you think this could be because of a conflict with another plugin by chance? Sometimes the code from different plugins collide unintentionally. To test, you can turn off all plugins except Jetpack and try testing with the Twenty Twelve theme again. If it works, turn each plugin back on one at a time until you see the problem happen again.

    For the record, I have tested Twenty Twelve using WordPress 3.4.2 and Jetpack 2.0.2 and infinite scroll works for me in tests of both the regular theme as well as an unmodified child theme (without any infinite scroll code added).

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic