Provides Ikiwiki::Plugin::opengraph

Iuri Guilherme a184f8e75d Versão 0.1.4 8 years ago
.gitignore 95ddeba113 Boilerplate 8 years ago
LICENSE 813600e0d8 Init commit 8 years ago
README.md a184f8e75d Versão 0.1.4 8 years ago
opengraph.pm a184f8e75d Versão 0.1.4 8 years ago

README.md

ikiwiki-plugin-opengraph

Name

Ikiwiki::Plugin::opengraph - Adds Open Graph tags on the html head

Description

This plugin implements the Open Graph tags in the head of the hmtl for all pages, provided you configure it properly and add it to the current template. For more information on what is Open Graph, visit https://en.wikipedia.org/wiki/Open_Graph. To test your site against the Open Graph rules, use the tool available on https://developers.facebook.com/tools/debug/og/object/.

Disclaimer

WARNING: Open Graph is modern spyware. You should use this if and only if you don't mind making the readers of your wiki/blog being tracked by evil corporations without their consent. By using this plugin you are being mean to the people who are reading your content. You have been warned.

Installation

Put opengraph.pm in ${HOME}/.ikiwiki/IkiWiki/Plugin/ or elsewhere in your @INC path. Or read http://ikiwiki.info/plugins/install/.

Configuration

Add to the configuration in your blog.setup file.

	## Open Graph plugin
	# For more information, see
	# <https://en.wikipedia.org/wiki/Open_Graph#Open_Graph_protocol>.
	# Default values for <http://ikiwiki.info>
	# obtained from <https://developers.facebook.com/tools/debug/og/object/>
	# meta property="og:title"
	opengraph_title: "ikiwiki"
	# meta property="og:type"
	opengraph_type: "website"
	# meta property="og:url"
	opengraph_url: "http://ikiwiki.info/"
	# meta property="og:image"
	opengraph_image: "http://ikiwiki.info/logo/ikiwiki.png"
	# meta property="og:description"
	opengraph_description: "Ikiwiki is a wiki compiler."

Add opengraph to the list of plugins:

	add_plugins: \[qw{goodstuff opengraph}\]

Templates

You will need to add the following code to page.tmpl on the current template. It must be in the section of the . I recommend puting it after the