Skip to main content
it's a matrix field
Source Link

I have a Matrix blockfield named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My Matrix block has no entries but is associated with a user.

enter image description here

enter image description here

How can I fetch the content of the Matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
    {{ dump(item) }}
{% endfor %}

But this is wrong.

How can I do it?

I have a Matrix block named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My Matrix block has no entries but is associated with a user.

enter image description here

enter image description here

How can I fetch the content of the Matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
    {{ dump(item) }}
{% endfor %}

But this is wrong.

How can I do it?

I have a Matrix field named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My Matrix block has no entries but is associated with a user.

enter image description here

enter image description here

How can I fetch the content of the Matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
    {{ dump(item) }}
{% endfor %}

But this is wrong.

How can I do it?

added 17 characters in body
Source Link
Brad Bell
  • 67.6k
  • 6
  • 75
  • 145

I have a matrixMatrix block named -> certificadocertificado

with block -> certificadoscertificados

and fields -> nomeDoCursonomeDoCurso, cursocurso, certificadocertificado

My matrixMatrix block has no entries, but is associated towith a user.

enter image description here

enter image description here

How can iI fetch the content of the matrixMatrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
    {{ dump(item) }}
{% endfor %}

But this is wrong. How

How can iI do it?

I have a matrix block named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My matrix block has no entries, but is associated to a user.

enter image description here

enter image description here

How can i fetch the content of the matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
{{ dump(item) }}
{% endfor %}

But this is wrong. How can i do it?

I have a Matrix block named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My Matrix block has no entries but is associated with a user.

enter image description here

enter image description here

How can I fetch the content of the Matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
    {{ dump(item) }}
{% endfor %}

But this is wrong.

How can I do it?

Source Link

Craft 3 - Matrix Block for currentUser

I have a matrix block named -> certificado

with block -> certificados

and fields -> nomeDoCurso, curso, certificado

My matrix block has no entries, but is associated to a user.

enter image description here

enter image description here

How can i fetch the content of the matrix block for a particular user in the frontend?

I'm trying with:

{% for item in currentUser.certificado %}
{{ dump(item) }}
{% endfor %}

But this is wrong. How can i do it?