• escaffe

    (@escaffe)


    Hi,

    I use Jetpack but I have not had Photon or Tiled Galleries activated. However, one of my images is serving with Insecure URL: https://i1.wp.com/atsouk.com/assets/themes/marketify-child/default-avatar.png

    It is the only image to be served with this prefix which is causing mixed content errors.

    This image is referenced to in a custom function in a child theme in order to add a new default image for my users.

    Here is the code:

    add_filter( 'avatar_defaults', 'crunchifygravatar' );
    
    function crunchifygravatar ($avatar_defaults) {
    $myavatar = 'https://atsouk.com/assets/themes/marketify-child/default-avatar.png';
    $avatar_defaults[$myavatar] = "Crunchify Avatar";
    return $avatar_defaults;
    }

    What do I do to either:

    1) remove the i1.wp.com prefix
    OR
    2) let the image be served with https instead of http?

    The easier method is preferred.
    Thank you for your time.

    https://www.ads-software.com/plugins/jetpack/

Viewing 1 replies (of 1 total)
  • Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic ??

    Could you try to dequeue Jetpack’s devicepx library? It is used to automatically resize and transform your images on Retina and HiDPi devices, and it is possible that it’s creating an issue when trying to resize the default Gravatar image. You can dequeue that file by adding the following snippet in your theme’s functions.php file, or in a functionality plugin:

    function dequeue_devicepx() {
    wp_dequeue_script( 'devicepx' );
    }
    add_action( 'wp_enqueue_scripts', 'dequeue_devicepx', 20 );

    If that doesn’t help, could you try to edit your crunchifygravatar function, and replace the image URL by its HTTPS version, hosted on Photon, like so:

    add_filter( 'avatar_defaults', 'crunchifygravatar' );
    
    function crunchifygravatar ($avatar_defaults) {
    $myavatar = 'https://i1.wp.com/atsouk.com/assets/themes/marketify-child/default-avatar.png';
    $avatar_defaults[$myavatar] = "Crunchify Avatar";
    return $avatar_defaults;
    }

    Let me know how that goes!

Viewing 1 replies (of 1 total)
  • The topic ‘Photon, Tiled Galleries has not been active but i1.wp.com is added’ is closed to new replies.