Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
PukiWiki gist plugin
<?php
/**
* gist.inc.php - embed gist
*
* Usage:
* #gist(231844)
* &gist(231844);
*
* @author makoto_kw
* @licence http://www.gnu.org/licenses/gpl.html GPLv2
* @link http://gist.github.com/231844
* @link http://code.google.com/p/google-code-prettify/
* @version 1.0
*/
function plugin_gist_convert() {
$args = func_get_args();
$gistid = array_pop($args);
return '<script src="http://gist.github.com/'.$gistid.'.js"></script>';
}
function plugin_gist_inline() {
$args = func_get_args();
array_pop($args);
$gistid = array_pop($args);
return '<script src="http://gist.github.com/'.$gistid.'.js"></script>';
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.