• Hello.

    To change the header image of the page

    I installed the unique-headers plug-in.

    However

    The header image is cut on mobile.

    I add it to style.CSS and use it.

    /*
    @media screen and (max-width: 480px) {
    .has-header-image.twentyseventeen-front-page .site-branding,
    .has-header-video.twentyseventeen-front-page .site-branding,
    .has-header-image.home.blog .site-branding,
    .has-header-video.home.blog .site-branding,
    .has-header-image.twentyseventeen-front-page .custom-header,
    .has-header-video.twentyseventeen-front-page .custom-header,
    .has-header-image.home.blog .custom-header,
    .has-header-video.home.blog .custom-header { height: auto;
    left: 0;
    max-width: 100%;
    min-height: 0;
    -o-object-fit: unset;
    object-fit: unset;
    position: relative;
    -ms-transform: none;
    -moz-transform: none;
    -webkit-transform: none;
    transform: none;
    }

    .has-header-image.twentyseventeen-front-page .site-branding,
    .has-header-video.twentyseventeen-front-page .site-branding,
    .has-header-image.home.blog .site-branding,
    .has-header-video.home.blog .site-branding,
    .custom-header-media,
    .has-header-image .custom-header-media img,
    .has-header-video .custom-header-media video,
    .has-header-video .custom-header-media iframe {
    position: static;
    }

    .custom-header-media:before {
    background: none;
    }

    body.has-header-image .site-description,
    body.has-header-video .site-description {
    color: #fff;
    opacity: 1;
    }

    .site-branding .wrap {
    padding: 0 1em;
    }
    }
    */
    The header image that is basically applied to the front page is

    Mobile size is resized and the width is not reduced.

    Pages that changed unique-headers plug-in header images

    The header image is truncated.

    There is no solution?

    Help me.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Does the issue go away after deactivating your plugins?

    Thread Starter ysuelvis

    (@ysuelvis)

    I appreciate your answer.

    Disabling this plugin will work fine.

    Existing header images are not truncated on mobile

    The entire image is displayed.

    But,

    When using the plugin, the header image is truncated.

    I would like to use a different header image for each page with this plugin.

    Help me.

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    In that case can you show us your website with this plugin active, so that we can debug the problem?

    Thread Starter ysuelvis

    (@ysuelvis)

    Thank you for your answer.

    I have no programmer.

    Debugging can not be performed.

    This is the contents of index.php file of this plugin.

    
    /*
    <?php
    /*
    Plugin Name: Unique Headers
    Plugin URI: https://geek.hellyer.kiwi/plugins/unique-headers/
    Description: Unique Headers
    Version: 1.7.11
    Author: Ryan Hellyer
    Author URI: https://geek.hellyer.kiwi/
    Text Domain: unique-headers
    License: GPL2
    
    ------------------------------------------------------------------------
    Copyright Ryan Hellyer
    
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    (at your option) any later version.
    
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    GNU General Public License for more details.
    
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
    
    */
    
    /**
     * Do not continue processing since file was called directly
     * 
     * @since 1.0
     * @author Ryan Hellyer <[email protected]>
     */
    if ( ! defined( 'ABSPATH' ) ) {
    	die( 'Eh! What you doin in here?' );
    }
    
    /**
     * Autoload the classes.
     * Includes the classes, and automatically instantiates them via spl_autoload_register().
     *
     * @param  string  $class  The class being instantiated
     */
    function autoload_unique_headers( $class ) {
    
    	// Bail out if not loading a Media Manager class
    	if ( 'Unique_Headers_' != substr( $class, 0, 15 ) ) {
    		return;
    	}
    
    	// Convert from the class name, to the classes file name
    	$file_data = strtolower( $class );
    	$file_data = str_replace( '_', '-', $file_data );
    	$file_name = 'class-' . $file_data . '.php';
    
    	// Get the classes file path
    	$dir = dirname( __FILE__ );
    	$path = $dir . '/inc/' . $file_name;
    
    	// Include the class (spl_autoload_register will automatically instantiate it for us)
    	require( $path );
    }
    spl_autoload_register( 'autoload_unique_headers' );
    
    new Unique_Headers_Instantiate;
    */
    

    I think that it will be helpful.

    The way I can do is here.

    Thank you very much.

    • This reply was modified 7 years, 3 months ago by Andrew Nevins.
    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    That’s okay I’m no programmer too, that’s why I need to see your website that has the problem to debug from there. Without seeing your website it’s very difficult to find the problem.

    Thread Starter ysuelvis

    (@ysuelvis)

    My website is local.

    I will attach a screenshot.

    Thank you very much.

    https://drive.google.com/open?id=16MmDAXjYdNQuna-aJbTdiza4tcHVsbtm

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    I’m afraid screenshots aren’t useful here. Can you emulate the problem instead by using a tool like CSSDesk or jsFiddle?

    Thread Starter ysuelvis

    (@ysuelvis)

    I can not solve the problem.

    It may not be able to solve the problem.

    But,

    To your action to support my problem

    I deeply appreciate it.

    Thread Starter ysuelvis

    (@ysuelvis)

    I do not know how to make your suggestions.

    This is the night.

    I am going home and sleeping.

    I appreciate your kindness once more.

    On the other side of the earth …

    I don’t think it will be possible to help unless you can show us an example of the code with this problem occurring.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Page Header image resize unique-headers plug-in’ is closed to new replies.