Hi!
I’m currently working with a client and building out a site and am creating some shortcodes to pull ad display content from the Learnpress LMS plugin.
My test shortcode is:
function hello_world_function() { return learn_press_get_template( 'single-course/meta/duration.php' ); } add_shortcode('hello_world', 'hello_world_function');
This particular example will pull a particular piece of content from one of their page templates using [hello_world].
The shortcode works great when placed into a Text element. However, when attempting to use a Raw Content element, the content displays outside of its container and at the beginning of the page.
An example can be found here:
You’ll see that “10 Weeks” is what is getting returned from the shortcode, but when placed inside a Raw Element it - for whatever reason - renders at the top of page, well outside of its container. However, when placed inside of a Text element, it appears inline as intended.
Any ideas on this?