Include Me is a powerful plugin that lets you to include in any post or page and external HTML or PHP file. For PHP files, they will be executed and their output included, so you can develop indipendent scripts that can be made available on posts or pages.
An example? You want to publish a report generated by some queries on a database. Just develop such script and make it to output an HTML fragment. Then include it on a page with Include Me.
Where is the advantage over developing a theme custom page? Let me answer with another question: what happens to theme custom pages when you change theme?
Include Me syntax
In any post or page Include Me is activate with a short code (without spaces between “[" and "includeme" word):
[ includeme file="filename"]
where the “file” attribute contains the filename to be included. Any textual file can be included and if it is a PHP file (with “.php” extension) it will be executed and its output included.
The filename can be relative (not starting with “/”) so it will be searched starting from the blog root folder (for technicians, ABSPATH will be added at the beginning). If the filename is absolute (starting with “/”) it will be used as is.
A second syntax is available and generate an iframe instead to include the file. The iframe syntax is:
[ includeme src="url"]
where “url” is a common web address. Any other attribute added to the short tag will be used as an iframe attribute. For example if you write:
[ includeme src="http://www.example.com" frameborder="0" width="500" height="400"]
the result will be
<iframe src=”http://www.example.com” frameborder=”0″ width=”500″ height=”400″></iframe>
Nice, isn’t it?
I widely used this plugin (and its old and incompatible version Include It) on my blogs.
by Stefano Lissa