-1

I am very new to the Expression Engine CMS, and I con't for the life of me figure out how I can get my plugin code to work inside an article.

I have it working great when embedded inside a template, but when I try to put the same code inside an article, it just renders it as text.

Template Embedding:http://ee.o7th.com/

Article Embedding:http://ee.o7th.com/index.php/about

You can see the embed code in the second link. but for those who need it here, it is simply:

{exp:o7thpdfembed form="hpAXWPa7ol*ucBDOxbinuA" id="Test-Form-Container-ID" class="Test-Form-Container-Class" style="height:800px;width:100%;overflow:auto;"}
This will be the files title.
{/exp:o7thpdfembed}
Kevin
  • 2,684
  • 6
  • 35
  • 64
  • I assume that I need to use a `Global Variable` however, how am I supposed to pass on the required parameters thusly... – Kevin Jun 26 '13 at 15:35
  • So your plugin is called "o7thpdfembed"? What's an article? We need to see your template code to help, and if it's related to your plug-in we'll need that code (or part of). But fundamentally I'd suggest a step back and if you could explain what you're trying to achieve and why you've written a plugin? – Peter Lewis Jun 26 '13 at 16:28
  • I've written a plugin because my client needed a dynamic way to pass a file ID, and embed a PDF into a page. Now, the plugin works perfect when embedded in a template, via the code above. However, when I try to put the same code into an article/entry/content page (whatever they call it), all it shows is the code above, and not the rendering – Kevin Jun 26 '13 at 17:40
  • the only thing that appears to be working is a Global Variable. http://ee.o7th.com/index.php/about – Kevin Jun 26 '13 at 17:53
  • "However, when I try to put the same code into an article/entry/content page" - what is this? an entry? or a template? if the former - is it a text field or wysiwyg field? If the latter, please provide all your template code. Providing links to the end result isn't helping diagnose the issue, we need more information about how it's put together, not what it looks like on output. What are the template groups names, what is the embed code, what is the embed group and template name? – Peter Lewis Jun 26 '13 at 18:54
  • sorry. it's a text field, and actually I already fixed it. I'll post solution as an answer – Kevin Jun 27 '13 at 16:08

1 Answers1

0

The solution was a nightmare to find, as it appears to not be documented anywhere in the EE documentation, nor could I find anything about it online.

Entries are not able to parse any EE code, other than custom template Global Variables. This got me thinking...

I installed a plugin called Allow EE Code, put in the proper tags {exp:allow_eecode} around my templates {body} tag, and was then able to utilize and run the code in the question inside an Entry

Kevin
  • 2,684
  • 6
  • 35
  • 64