Output Matrix Content from Sibling I need to get Matrix field content from a entries sibling. Essentially, I have a block type called gallery within my project pages, and under the project content on each page, I have a section for Other Recent Projects. I'd like to be able to get the first image from the gallery block of the previous and next siblings and output it in this recent projects section. How can I do that?

Thanks,
J
Something like this might work (obviously, replace the matrixField, assetsField and imageTransform handles with real values):

{# Basic query parameters for your sibling entries #}
{% set siblingCriteria = craft.entries.section(entry.section.handle) %}

{# Creates an array with the next and previous entries, based on the basic query parameters #}
{% set siblingEntries = [entry.getPrev(siblingCriteria), entry.getNext(siblingCriteria)] %}

{# Loop through the next and previous entries
{% for siblingEntry in siblingEntries %}

    {% if siblingEntry %}{# This might be null, if there isn't a next or previous entry #}

        {# Get the first `gallery` block for the entry's Matrix field #}
        {% set galleryBlock = siblingEntry.matrixField.type('gallery').first() %}

        {# Get the first asset in the gallery block's Assets field #}
        {% set galleryImage = galleryBlock ? galleryBlock.assetsField.first() : null %}

        {# Render the image #}
        {% if galleryImage %}
            &lt;a href="{{ siblingEntry.url }}"&gt;
                &lt;img src="{{ galleryImage.getUrl('imageTransform') }}" /&gt;
            &lt;/a&gt;
        {% endif %}

    {% endif %}

{% endfor %}