aboutsummaryrefslogtreecommitdiff
path: root/_build/data
diff options
context:
space:
mode:
authorVictor Häggqvist <[email protected]>2014-06-22 13:40:55 +0200
committerVictor Häggqvist <[email protected]>2014-06-22 13:40:55 +0200
commit61a021a728e3dfa7b452b1884188780e6dcae01e (patch)
tree63e1a1d6dc15228e9e1cf346811881f8e32c08f4 /_build/data
init
Diffstat (limited to '_build/data')
-rw-r--r--_build/data/transport.snippets.php23
1 files changed, 23 insertions, 0 deletions
diff --git a/_build/data/transport.snippets.php b/_build/data/transport.snippets.php
new file mode 100644
index 0000000..b9548d6
--- /dev/null
+++ b/_build/data/transport.snippets.php
@@ -0,0 +1,23 @@
+<?php
+/**
+ * @package parsedown
+ * @subpackage build
+ */
+function getSnippetContent($filename) {
+ $o = file_get_contents($filename);
+ $o = trim(str_replace(array('<?php','?>'),'',$o));
+ return $o;
+}
+
+$snippets = array();
+
+$snippets[1] = $modx->newObject('modSnippet');
+$snippets[1]->fromArray(array(
+ 'id' => 1,
+ 'name' => 'Parsedown',
+ 'description' => 'A markdown parser with GFM support',
+ 'snippet' => getSnippetContent($sources['elements'].'snippets/snippet.parsedown.php'),
+),'',true,true);
+
+return $snippets;
+