[Support request] Elementor Archives Overiding Page Width Setting

Home Forums Support [Support request] Elementor Archives Overiding Page Width Setting

Home Forums Support Elementor Archives Overiding Page Width Setting

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #813043
    Antar

    Hello,

    I’m having trouble controlling the page width for archive pages created with Elementor. A normal page shoud be fixed at 1200px but archive pages are going to full width.

    Normal: https://prnt.sc/mme8db
    Archive: http://prntscr.com/mme83z

    I’ve checked the CSS and can see a new “.full-width-content” class added to the body tag of the archive pages: http://prntscr.com/mme93p

    This is taking precendence over the normal “.grid-container” class.

    I’ve tried to take control by using a page layout element – but nothing seems to work.

    Any ideas?

    Thanks,

    Antar

    #813054
    Leo
    Staff
    Customer Support

    Hi there,

    Metabox doesn’t work on blog/archive pages by WordPress default.

    The only way to apply full-width container to blog/archive pages is to use Layout Element:
    https://docs.generatepress.com/article/layout-element-overview/#container

    Can you check if that’s the case for you?

    #813055
    Antar

    Leo –

    You misunderstand. I DON’T want full-width. I want the content width to remain the same (1200px) as on all other pages.

    Antar

    #813057
    Leo
    Staff
    Customer Support

    I think you misunderstood.

    Do you have a layout element created that’s making the blog/archive page full-width?

    That should be the only reason those pages have full-width container applied to them.

    #813062
    Antar

    Hi, Leo –

    No the Elementor layout is not full-width. Please see the screenshot: http://prntscr.com/mmf07u

    You can also see that the content width is wider than the rest of the page.

    Antar

    #813100
    Leo
    Staff
    Customer Support

    I’m not talking about Elementor.

    Do you have a layout element created that’s making the blog/archive page full-width?

    https://docs.generatepress.com/article/layout-element-overview/#container

    #813102
    Antar

    `Hi, Leo –

    No. I have created an element in an attempt to control the content width:

    http://prntscr.com/mmfknl
    http://prntscr.com/mmfkei

    This is set to the “contained” option.

    Antar

    #813105
    Leo
    Staff
    Customer Support

    Do you have another layout element that’s setting the container width for other pages?

    We know the options work for sure. Just need to find what’s applying the full width options for those pages.

    Make sure your caching plugin is cleared as well.

    #813253
    Antar

    Hi, Leo –

    I’ve done some more tests and can confirm this is a bug in Elementor. There is another post about it on this forum, here: Custom post templates in elementor show full width in boxed mode

    Elementor is injecting the class full-width-content into the body tag automatically – even if the layout is set to “contained”.

    We need a work-around.

    Antar

    #813400
    David
    Staff
    Customer Support

    This came up on Elementor GitHub – the snippet actually works but it would be better to get behind the issue with Elementor and have them resolve it at source:

    https://github.com/elementor/elementor/issues/5636#issuecomment-464561021

    #889482
    Dean

    Just to note … I see this issue is still relevant (Elementor single post templete layout set to “contained” does not adhere to setting; shows as full-width) … although adding this code to my functions.php file in my child theme solved the issue.

    Hopefully you can convince the Elementor team to fix the bug!

    #2324858
    niall

    Apologies for resurrecting an old thread but I came across this exact issue today (in 2022), basically the Elementor Archive and Single page templates are adding a “full-width” class to the container element which is overriding the Generatepress layout settings, so it still hasn’t been fixed on the Elementor side, the snippet in the github link that David posted above resolves the issue

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