Editorial Workflows

Post Markdown to WordPress

public workflow

Install Workflow...

This workflow contains at least one Python script. Only use it if you trust the person who shared this with you, and if you know exactly what it does.

I understand, install the workflow!

This is a workflow for Editorial, a Markdown and plain text editor for iOS. To download it, you need to view this page on a device that has the app installed.

Description: **Note:** This is an update to my earlier "Post Markdown to WordPress" workflow.

Take a Markdown document and post it to a WordPress blog. Since WordPress now will accept Markdown directly there is no conversion to HTML done on the document. This workflow allows choosing a category(ies), entering post tags, choosing a post status, and scheduling a post by giving a date in the future.

The workflow also looks for a Multimarkdown "Title:" tag at the top of the file. If one is found a choice of that title or the file name is given for use as the post title.

Enter your blog details in the parameters for the Get Connection Details action. "Service" is just a key used to store your blog password; it can be anything you like. Reset Password, copied from Federico Viticci's posting workflow, allows you to clear your stored password.

Shared by: http://jasonkratz.com

Comments: Comment Feed (RSS)

Sandra — 17 Jul 2016
Thanks for a great tool! I found that I had to change "http:" to "https:" in order to work around a "xmlrpc permanently moved" error, but other than that it's working perfectly for me.
Lou — 13 Sep 2016
Only thing I am noticing is I can't set my WordPress site to accept Markdown. I keep looking at the settings but don't see the option. The Workflow worked great and was easy to setup. I have it set to draft since Markdown is not being interpreted on my wordpress site.
Lou — 13 Sep 2016
I found the option. It is under Jetpack and now it works perfect!!!

+ Add Comment

Workflow Preview
Set Variable ?
Variable Name
userid
Value
Set Variable ?
Variable Name
url
Value
Set Variable ?
Variable Name
service
Value
Input
Get Connection Details ?
Get Category List From WP ?
Choose A Category ?
Title
Choose a Posting Category(ies)
List (Lines)
Input
Multiple Selection
ON
Show in Popover
OFF
Set Variable ?
Variable Name
categories
Value
Input
Enter Post Tags ?
Title
Enter Post Tags
Initial Text
  • Single Line
  • Multiple Lines
Keyboard Options:
Remove Whitespace ?
  • Trim leading/trailing whitespace
  • Remove empty lines
Set Variable ?
Variable Name
tags
Value
Input
Choose A Post Status ?
Title
Post Status
List (Lines)
Draft draft Published publish Private private
Multiple Selection
OFF
Show in Popover
OFF
Set Variable ?
Variable Name
postStatus
Value
Input
Show Alert ?
Title
Set a post date?
Message
Button 1
Yes
Output Value
yes
Button 2
No
Output Value
no
Button 3
(don't show)
Output Value
Show Cancel Button
OFF
If… ?
Run the block if
Input
  • is Equal to
  • is Not Equal to
  • Contains
  • Doesn't Contain
  • Matches Regular Expression
yes
Choose Post Date ?
User Interface
Presentation Style
  • Sheet
  • Full-Screen
  • Popover
Output
%ui:datepicker1
Use Editor Theme
ON
Set Variable ?
Variable Name
postDate
Value
Input
…End If
Get Current File Name ?
Include Folder
OFF
Include Extension
OFF
Set Variable ?
Variable Name
filename
Value
Input
Move Caret ?
Direction
  • Backward
  • Forward
  • Start/End of Document
  • Start/End of Line
  • Number of Characters:
1
Document Text ?
Folded Text
  • Include
  • Replace with:
Set Variable ?
Variable Name
text
Value
Input
Filter Lines ?
Output Lines That
  • Contain
  • Don't Contain
  • Match Regular Expression:
^Title:.*
Output Format
  • Only Lines
  • Lines and Ranges
Set Variable ?
Variable Name
mmdTitleLine
Value
Input
If MMD Title Found: ?
Run the block if
mmdTitleLine
  • is Equal to
  • is Not Equal to
  • Contains
  • Doesn't Contain
  • Matches Regular Expression
^Title:
Document Text ?
Folded Text
  • Include
  • Replace with:
Check for MMD Title ?
Output Lines That
  • Contain
  • Don't Contain
  • Match Regular Expression:
^Title:.*
Output Format
  • Only Lines
  • Lines and Ranges
Set Variable ?
Variable Name
title
Value
Input
Find ?
Search for
(\d+):(\d+)
Match Group (RegEx)
2
Search Type
  • Regular Expression
  • Case-insensitive Search (A = a)
  • Case-sensitive Search (A ≠ a)
Output
  • Found Text
  • Range of Text (from:to)
Set Variable ?
Variable Name
startOfText
Value
Input
Generate Text ?
Text
mmdTitleLine
Get the title string ?
Search for
^Title:\s(.*)
Match Group (RegEx)
1
Search Type
  • Regular Expression
  • Case-insensitive Search (A = a)
  • Case-sensitive Search (A ≠ a)
Output
  • Found Text
  • Range of Text (from:to)
Remove Whitespace ?
  • Trim leading/trailing whitespace
  • Remove empty lines
Set Variable ?
Variable Name
mmdTitle
Value
Input
Generate Text ?
Text
title
Find ?
Search for
^Title:\s(\s\w)
Match Group (RegEx)
1
Search Type
  • Regular Expression
  • Case-insensitive Search (A = a)
  • Case-sensitive Search (A ≠ a)
Output
  • Found Text
  • Range of Text (from:to)
Select Range ?
Range (from:to)
startOfText:
Relative to
  • Entire Document
  • Current Selection
Remove Whitespace ?
  • Trim leading/trailing whitespace
  • Remove empty lines
Set Variable ?
Variable Name
text
Value
Input
Select from List ?
Title
List (Lines)
mmdTitle filename
Multiple Selection
OFF
Show in Popover
OFF
Set Variable ?
Variable Name
selectedPostTitle
Value
Input
…End If
Create Post ?
Deselect Text In Editor ?
Range (from:to)
0:0
Relative to
  • Entire Document
  • Current Selection
Show HUD ?
HUD Text
Post selectedPostTitle created!
Duration
  • 1 Second
  • 2 Seconds
  • 3 Seconds
Icon
  • "Success"
  • "Error"