WordPress.org

Ready to get started?Download WordPress

Forums

Oxygen
Gallery with same width of featured posts in home page? (3 posts)

  1. JonasK
    Member
    Posted 1 year ago #

    Is it possible that the gallery inside the posts look like the featured posts in the home page?

    I'm developing a website with Oxygen theme that has a group of images associated with every post. I'm using the media gallery at the end of each post.

    The problem is that the images in the gallery view stay with the width of the central column and I was wondering if it`s possible that the gallery looked like the featured posts in the home page – I mean the images appear larger, with the width of the central and right columns.

  2. JonasK
    Member
    Posted 1 year ago #

    Or something like the “full width” page template for the exhibition of the gallery...

  3. JonasK
    Member
    Posted 1 year ago #

    My version for the “full width gallery”:

    1) Disable left column
    Comment (Php and Hmtl) or erase lines 14 to 20 in
    wp-content/themes/oxygen/attachments.php

    <div class="aside">
    
    <?php get_template_part( 'menu', 'secondary' ); // Loads the menu-secondary.php template.  ?>
    
    <?php get_sidebar( 'primary' ); // Loads the sidebar-primary.php template. ?>
    
    </div>

    2) Disable right column
    Change line 113 in wp-content/themes/oxygen/functions.php from this:

    if ( is_page_template( 'page-template-fullwidth.php' ) ) {

    to this:

    if ( is_page_template( 'page-template-fullwidth.php' ) or is_attachment() ) {

    3) Adjust CSS
    Add this after “Contact Form 7 (plugin)” and before “Media Queries (mobile browsing)” in wp-content/themes/oxygen/style.css (line 1385)

    /*  Gallery Full Width
    ----------------------------------------------------- */
    .attachment-image .content-wrap { width: 100%; }
    .attachment-image #content { width: 100%; }

    It is working for me, hope to send the link to the website soon...

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic