I edit an old, large EE1 site with lots of weblog articles, some containing flash content. We want to change that content into HTML5/css/java but that requires specific code to get into the head section on a post by post basis and I can't figure out how to do it. Is it possible?

The basic template has an embedded 'head' section and a channel entry loop with some custom fields.

I see how to get the 'title' into the head by passing it through the 'embed' tag. I tried to add a second embed that referred to a custom field from the channel but the content doesn't get passed, only the name of the custom field.

{exp:weblog:entries weblog="modules" orderby="date" sort="desc" limit="1" disable="member_data|trackbacks|pagination|categories|custom_fields"} embed="site_embeds/html_head" my_page_title="{title}" special_head_code="{special_head}"}{/exp:weblog:entries}

Can anyone help me find a solution?

  • That should work. Post some surrounding code so we can see the Channel Entries tag that the embed lives inside? Commented Feb 22, 2013 at 13:26
  • you have your custom_fields disabled :-) and the opening moustache is missing from your embed :-)
    – GDmac
    Commented Feb 22, 2013 at 14:18
  • Thanks GDmac, the disabled thing was a bit dumb on my part. The missing bracket crept in when I pasted the code here. Will press on and see if it works with the java. Commented Feb 22, 2013 at 14:27
  • but does it work now with custom_fields no longer disabled?
    – GDmac
    Commented Feb 22, 2013 at 19:19
  • No. Please see a comment below. Commented Feb 23, 2013 at 9:08

2 Answers 2


You have to remove "custom_fields" from your disable="member_data|trackbacks|pagination|categories|custom_fields" parameter. This is telling EE not to process custom fields which is why the custom field name is printing out and not the data you are expecting.

Once you remove this, your code will work as expected.

  • 1
    Anna hit the nail in the head here. You're specifically turning off custom field support.
    – Ian Pitts
    Commented Feb 26, 2013 at 22:03

Ah, if you put javascript or html with quotes inside a parameter, the problem is nested quotes

// {var="oops "nested" quotes"}
   {var='this "works" ... '}

Try to surround the parameter with 'single quotes'. This always has been a bit problematic and fragile. If a user then enters single quotes in a field, then the nested quotes problem will show up again. A plugin (stash, or your own custom) is able to store tagdata, and probably is the only way to do this in a safe way.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.