Skip to content

Update email templates to use liquid syntax for PMPro 3.7+#220

Open
dparker1005 wants to merge 1 commit intostrangerstudios:devfrom
dparker1005:liquid-email-templates
Open

Update email templates to use liquid syntax for PMPro 3.7+#220
dparker1005 wants to merge 1 commit intostrangerstudios:devfrom
dparker1005:liquid-email-templates

Conversation

@dparker1005
Copy link
Copy Markdown
Member

Summary

  • Adds PMPro_Liquid_Renderer class existence check to get_default_body() and get_email_template_variables_with_description() methods across all 5 email template classes.
  • When the class exists (PMPro 3.7+), uses {{ variable }} liquid syntax; otherwise falls back to !!variable!! syntax for backward compatibility.
  • get_default_subject() methods were not changed as they do not use template variable syntax.
  • get_email_template_variables() methods were not changed as they do not use !! syntax.

Test plan

  • Verify emails render correctly with PMPro 3.7+ (liquid syntax {{ }} should be used)
  • Verify emails render correctly with PMPro < 3.7 (legacy !! syntax should be used)
  • Test each email type: admin approved, admin notification approval, application approved, admin denied, application denied

🤖 Generated with Claude Code

Uses {{ }} variable syntax when PMPro_Liquid_Renderer is available,
falling back to !! syntax for older versions of PMPro.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant