We'll create fresh WordPress site with http-syndication installed. You have 20 minutes to test the plugin after that site we'll be deleted.
This plugins offers the following “ground” functionnalities:
In order to render the raw content of a post or page without any header, sidebar and footer use the link:
http://#mywordpressadress?httpsyndication&p=#post_or_page_id&title=#1_or_0
where:
#mywordpressadress
is the wordpress web site adress.#post_or_page_id
is the post or page id (you can read the post id in the http link when you edit the post).#1_or_0
defines whether the post title (enclosed in a <h1>
HTML tag) is displayed (default is 1
, i.e., true).Remarks:
#
, e.g., #tag
or #id
correspond to a variable, e.g., #tag
means any tag name or #id
means an ID label.In order to import an external a post or page contents in another post or page, use the following shortcode:
[import url="#external_resource_location" ]
where:
#external_resource_location
is the external web site http location.Inside the [import ..]
shortcode, the following options allows to select and adjust the content to import:
body=1
: in order to only import the <body..>..</body>
part of the <html><head>..</head><body..>..</body></html>
page.tag_id=#id
: only extract the content of the 1st tag of the given id, i.e. the <#tag id="#id">..</#tag>
part, where #tag
is any tag (e.g., div
, span
, ..). tag_class=#class
: only extract the content of the 1st tag of the given class, i.e. the <#tag class="#class">..</#tag>
part, where #tag
is any tag (e.g., div
, span
, ..); the value #class
can be a regex to deal with multiple defined classes. tag_name=#name
: only extract the content of all tags of the given name, i.e. the <#name ..>..</#name>
part (for code safety only 100 tags can be extracted). noscript=1
: in order to delete all <script..>..</script>
parts, avoiding any active JavaScript running from the imported HTML.raw_href=1
: in order to provide raw href values, instead of properly relocating relative href in the source HTML code, as done by default.mediawiki=1
: adds the ?printable=yes&action=render
query to the URL, in order to properly syndicate mediawiki sites.style=#style
or class=#class
allows to encapsulate the content in a <div .
with customized class and/or style attribute.Example :
[import url="http://localhost/wordpress/?cat=4687" tag_id="content" style="width:100%"]
allows to import a category rendering with another page.How can i know with id, tag or class to select?
Remarks:
allow_url_fopen
option to be validated in the PHP configuration, otherwise an error message is produced in the page output.noscript=1
, the external JavaScript code is imported. Though security flaws are normally not to be expected considering usual JavaScript security rules, clearly malicious code can easily hugely perturb the page rendering.In order to import a post or page contents in another post or page, use the following shortcode:
[import id="#post_or_page_id"]
to include the filtered content of another post or page in the current content.[import id="#post_or_page_id" content=1]
to include the raw (with shortcode expanded, but not content filter applied) of another post or page in the current content (to be used only if required).[import id="#post_or_page_id" title=1]
to include the title of another post or page in the current content.where:
#post_or_page_id
is the post or page id (you can read the post id in the http link when you edit the post).Remarks:
These additonal functionalities are deprecated but still available for backward compatibility
Using the ?w=#id
query allows to refer any page, post or archive by its numerical index.
Using the [import wform=1 label="#theinputlabel"]
shortcode, allows to insert a small input field to switch to any page, post or archive given its numerical index.
Using the [import banner="#page_id" url="#external_url"]#link-text[/import]
shortcode allows to display another site page in an iframe, with a banner from this site sitting on top of the external page. Inside the [import ..]
shortcode, the following options allows to adjust the behavior.
header=false
: in order to include or not the usual site header().php on the top of the bannerheight=1000
: in order to adjust the height of the frame for very long external pages.newtab=1
: in order to open the page and banner in a new browser window.style="border:none;"
: in order to adjust the height of the frame for very long external pages.