admin管理员组文章数量:1289542
I made a shortcode which I put in the popup. The shortcode just needs to get the content of the page by ID I created in Elementor and show it in a popup with the same design as it is on the inner page.
$content_post = get_post(1000);
return do_shortcode( apply_filters( 'the_content', $content_post->post_content ) );
Using this code, the current page is loaded into the popup, not with ID 1000 with markup and styles.
If I use code without a filter:
return do_shortcode( $content_post->post_content );
I am getting content from the page I want, but it is without design from html markup.
Why is this so? How do I load the page I want into the popup with all the markup and styles I have configured in Elementor?
I made a shortcode which I put in the popup. The shortcode just needs to get the content of the page by ID I created in Elementor and show it in a popup with the same design as it is on the inner page.
$content_post = get_post(1000);
return do_shortcode( apply_filters( 'the_content', $content_post->post_content ) );
Using this code, the current page is loaded into the popup, not with ID 1000 with markup and styles.
If I use code without a filter:
return do_shortcode( $content_post->post_content );
I am getting content from the page I want, but it is without design from html markup.
Why is this so? How do I load the page I want into the popup with all the markup and styles I have configured in Elementor?
Share Improve this question edited Aug 4, 2021 at 7:01 VladSiy asked Aug 4, 2021 at 6:23 VladSiyVladSiy 57 bronze badges1 Answer
Reset to default 0Unfortunately, I was too hasty with the question. Luckily I found the answer to my question here.
本文标签: phpWhy is the current page loaded in the popup window and not the specified one
版权声明:本文标题:php - Why is the current page loaded in the pop-up window and not the specified one? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741405730a2376933.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论