Improved Include Page plugin allows to include the content of a static page in a template file with several options. Since version 0.4.4 IIP uses Wo
wp-content/pluginsdirectory of your WordPress installation
iinclude_pagefunction or in your pages/posts using the shortcode syntax.
After installing it, the plugin adds the function ´iinclude_page´:
void iinclude_page(int post_id [,string params, boolean return = false])
The function takes three parameters: the id of the page to include (
post_id) and an optional string (
params) which contains the display options and an optional boolean (
return) tells wether to return the content or display it on screen.
If you wish to include the content of page number
4 insert the following code into your template file (eg. sidebar.php):
<?php iinclude_page(4); ?>
<?php echo iinclude_page(4, null, true); ?>
In order to avoid PHP errors you should use the function with the following syntax:
<?php if(function_exists('iinclude_page')) iinclude_page(4); ?>
You can also display the page title using the following code:
<?php iinclude_page(4,'displayTitle=true&titleBefore=<h2 class="sidebar-header">'); ?>
You can include a page's content in a page/post using the syntax:
[include-page id="3" displayTitle="true" displayStyle="DT_TEASER_MORE" titleBefore="<h3>" titleAfter="</h3>" more="continue»"]
The current version supports the following parameters:displayTitle (boolean) toggle title display titleBefore/after (string) string to display before and after the title displayStyle (integer constant) one of the following:
Requires: 1.5.3 or higher
Compatible up to: 3.0.5
Last Updated: 2010-6-26
0 of 1 support threads in the last two months have been resolved.
Got something to say? Need help?