Archived ExpressionEngine Uncategorized

Allow EE code in EE with ‘Allow EE Code’

One of the great features of ExpressionEngine is that you can change pretty much everything that affects layout. EE tags are a big part of this but I found that by default you can have EE tags inside templates, obviously, but not inside entries. Putting EE tags into entries will simply show the EE tags in the browser when viewing the entry – not good. So, how do we do this?

The first step is to download and install the ‘Allow EE Code‘ plugin, a first-party plugin from the makers of ExpressionEngine. As always the best place to get info about the EE plugin manager is the EE documentation.

Without going into too much detail the remaining steps are as follows.

  • Edit your custom fields, in particular the ones you’ll be using EE tags in. Edit the list ‘Default Text Formatting for This Field’ and make sure the option ‘Allow EeCode’ is set to ‘Yes’.
  • Unless you set the default text formatting drop-down box on the previous screen to ‘Allow Eecode” you’ll also need to set ‘Allow override on publish page?’ to ‘Yes’.
  • Next time you edit or publish an entry you’ll be able to have EE tags in your entries IF you set the default text formatting option to ‘Allow Eecode’. If not you’ll have to change the default text formatting from ‘XHTML’ to ‘Allow Eecode’. See the previous setup if you don’t have that option available.

I was trying to do this so that I could use the Freeform plugin by Solspace inside an entry instead of inside a separate template.

Hope that helps someone. 🙂