Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var title = '%filltext:name=Title%';
- slug = title.replace(/[^\w\s]/gi, '');
- var newslug = title.split(" ").join("-");
- var dt = new Date();
- TextExpander.appendOutput("— \n");
- TextExpander.appendOutput("layout: post \n");
- TextExpander.appendOutput("title: " + title + "\n");
- TextExpander.appendOutput("tags: \n");
- TextExpander.appendOutput("published: true \n");
- TextExpander.appendOutput("permalink: ") +TextExpander.appendOutput(newslug.toLowerCase()); + TextExpander.appendOutput(" \n");
- TextExpander.appendOutput("date: ") + TextExpander.appendOutput(dt.getFullYear() + "-" +(dt.getMonth() +1) + "-" + dt.getDate()) + TextExpander.appendOutput("\n");
- TextExpander.appendOutput("summary: \n");
- TextExpander.appendOutput("— \n");
- // %filltop%
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement