• I have begun using Presswell Art Directed images in my theme, however, I am getting inconsistent results with attempting to display them. I have added image sizes like so:

    pwad_add_image_size( array(
    'name' => 'Art-directed post thumbnail',
    'key' => 'pwad-post-thumbnail',
    'width' => '1920',
    'height' => '1920',
    'thumbnails' => array(
    array(
    'name' => 'Banner',
    'key' => 'pwad-banner',
    'width' => '1920',
    'height' => '700',
    ),
    array(
    'name' => 'Hero',
    'key' => 'pwad-hero',
    'width' => '1920',
    'height' => '846',
    ),
    array(
    'name' => 'Index thumbnail',
    'key' => 'pwad-index-thumb',
    'width' => '640',
    'height' => '480',
    ),
    ),
    ) );

    I have additional post images using ACF which are set to display via Image ID. In one instance, this works:

    echo pwad_get_image( $image, 'pwad-post-thumbnail-pwad-banner' );

    This works with the overload pattern only, not with the standard pattern.

    On a different page, I receive the following error:

    Warning: Trying to access array offset on value of type bool in?/Users/<my user>/Sites/<my site name>/app/public/wp-content/plugins/presswell-art-direction/presswell-art-direction.php?on line?557

    var_dump on my $image reveals a string with a length of 0:

    string(0) “”

    That’s a clear indicator that the image is considered nonexistent, but I can’t figure out why PWAD isn’t producing a thumbnail of this image. Any idea as to why that might be?

  • The topic ‘Trying to access array offset on value of type bool…in presswell-art-direction’ is closed to new replies.