Blog Sections Open

Escaping Double Curly Braces in Evolution CMS Templates and Chunks

How to keep third-party JavaScript templates that use {{ and }} intact without letting Evolution CMS treat them as its own syntax.

Frontend libraries often use {{ ... }} placeholders, but that becomes awkward in systems that also parse template-like delimiters. When you embed a JavaScript widget or frontend template directly into a chunk, those braces can be interpreted or altered before the browser ever sees them.

The safest solution is to keep the JS template out of the parser path whenever possible.

Practical options

  • Move the JavaScript template into an external file.
  • Store it in a place the Evolution parser will not try to process.
  • If it must stay inline, output it through a mechanism that preserves the literal braces.

Externalizing the script is usually the cleanest option. It keeps frontend syntax intact, reduces parser conflicts, and makes maintenance easier when the library changes.

Whenever a frontend plugin relies on literal curly-brace tokens, treating that template as static asset content is usually better than forcing it through CMS parsing.

Newer post

Updating TV Values for a Specific Resource Through the Evolution API

A straightforward pattern for changing one resource TV programmatically instead of trying to fake the edit form by hand.

Older post

Allowing Frontend Uploads into easy2gallery Safely

A practical outline for accepting user photo uploads on the frontend while still keeping easy2gallery manageable and safe.