0

I want to embed existing modules into the content of my custom component. I thought I could simply use {loadmoduleid 123} within the text of my component record and on display of this record, the module would be displayed. Alas this didn't work despite having the Content - Load Module plugin enabled. Does this mean I have to create my own loadmodule plugin for my component? Or is there a way to utilise the core plugin, if so how. Any and all advice/guidance appreciated.

Edit: So for some further clarification, my component has fields (title, description) in the record and I want my component to display the description which may or may not contain within the text {loadmoduleid 123} which is generally positioned somewhere in the HTML text.

So in my code I would generally just display the field contents:

<?php echo $this->item->description; ?>

and if the contents of the {loadmoduleid 123} and module_id 123 was a custom HTML module with just an image, then the output should be something like:

<p>Blah blah blah . . . <img src="images/testimage.jpg" alt="Test Image" /> blah blah blah.</p>
3

0

Your Answer

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

Browse other questions tagged or ask your own question.