seo icon indicating copy to clipboard operation
seo copied to clipboard

Custom fields are not evaluated anymore using Dynamic Entry synthax in Craft 4

Open juban opened this issue 3 years ago • 0 comments

Description

When setting a Page Title or Page Description using the dynamic entry synthax, custom fields are not evaluated anymore in Craft 4. This is due to an Internal change in the attributes() Element method which does not return custom fields as in Craft 3.

Steps to reproduce

  1. Add a field named common_title to a section
  2. Set SEO Page Title as {% if object.common_title %}{common_title}{% else %}{title}{% endif %}.
  3. Resulting title will always be the title value. Outputing {common_title} directly will always result in a empty string.

Additional info

  • Craft version: 4.0.5
  • SEO version: 4.0.3
  • PHP version: 8.0.18

juban avatar Jun 25 '22 17:06 juban