Site logo

[Resolved] GP + LearnPress styling question

Home Forums Support [Resolved] GP + LearnPress styling question

Home Forums Support GP + LearnPress styling question

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #729402
    Mike

    Using the LearnPress plugin. At the Lesson level, the pages can’t be tweaked in Customize. Is it possible to wrap these pages so that Customize global container settings apply?

    #729437
    Tom
    Lead Developer
    Lead Developer

    Hi there,

    Does LearnPress have any instructions for integration with themes? I assume they must have some sort of option to make their plugin work with any theme.

    #729446
    Mike

    LearnPress lets you override its own templates by copying the template folder to the theme folder and renaming it “learnpress”.

    The higher level pages work within GP.

    #729814
    Tom
    Lead Developer
    Lead Developer

    So there are no specific instructions for theme integration? That’s strange.

    So what I would do is create a new file in the learnpress child theme folder named content-single-item.php (at least I think that’s the template we’re working with?).

    Then, make the contents of that file the same as the theme single.php: https://github.com/tomusborne/generatepress/blob/master/single.php

    Then copy what’s currently in their file (highlighted): https://github.com/LearnPress/learnpress/blob/develop/templates/content-single-item.php#L18-L40

    And replace the following in the new file you created with it: https://github.com/tomusborne/generatepress/blob/master/single.php#L26-L43

    #729907
    Mike

    Thanks! I will attempt and post back.

    There is a LearnPress docs wiki, with a section on theming, but unfortunately it’s still blank (it was mentioned in another GP forum post).

    #730270
    Mike

    That didn’t work, I think I have to find the right template. It’s a tangle of CSS in there, the GP code appears to be in the page source, but overridden.

    I will try to untangle it, and ask for help here if there’s something very specific.

    Will reopen this thread if there are positive results!

    Thanks!!!

    #730407
    Tom
    Lead Developer
    Lead Developer

    No problem – here if you need us 🙂

    #743020
    Mike

    Been plugging away at this. To recap: LearnPress custom post type Lesson pages are not displaying properly within the GP page template (link in original post).

    • global $template; shows page.php.
    • The page source shows everything properly nested, but in Inspect Element, most of the LP content code appears after GP site footer.
    • On the displayed page, the LearnPress content appears on top of the GP page template content (primary nav, sidebar, etc) – I can position down (top:) the LP content to show the GP content.

    It seems that for rendering, something is popping the LP content out of the GP HTML order.

    Hope that makes sense!

    Thanks.

    #743317
    Tom
    Lead Developer
    Lead Developer

    That’s very strange – have you checked with LP support yet? GP isn’t doing anything special with the templates, so I’m not sure what the issue could be. They might be able to shed some light on it for us.

    #743402
    Mike

    Yeah, I’m spending way too much time on this, but it seems so close (and yet so far) . I just tested it with a different theme and the same problem happens, so I guess I’m on my own. I did post on their WP.org support forum, no dev replies there for the last month, and trying to figure out if there is a premium route to an answer.

    Thanks for your help! Support here is awesome.

    I will post back if it gets solved. LearnPress seems great for at least testing courses, so it’s a shame if one display problem knocks it out.

    Cheers.

    #743982
    Tom
    Lead Developer
    Lead Developer

    Sorry we weren’t able to help more. I’ll try to find some time to play with it.

    #754999
    Mike

    UPDATE: I think the way the lessons display is just the way LearnPress works. I checked other templates and LP’s own demo, and they’re all the same. Kinda makes sense, to make sure the 2-column lessons layout works, it sits on top of and hides the theme’s own stuff.

    Anyhow, not ideal, but I’m using as-is for now.

    #755085
    Tom
    Lead Developer
    Lead Developer

    Thanks for the update! Appreciate it 🙂

    #1493483
    cjenti

    hi all!
    I know this is an old topic, anyway, I had to find a solution about it last days…
    I found it there:
    https://www.ugenegrg.com.np/learnpress-lesson-template-changes/

    have a nice day!

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