Welcome to what very may well be one of the first of many in an ongoing series of posts where I share some of the more useful, (and successful), actions I have written for the iOS apps Launch Center Pro and Drafts4.
In this, um, should I call these issues? Anyway, in this issue, I’ll share my LCP (Launch Center Pro), action for using the text of a document stored in Dropbox as the text of a new blog post in the WordPress for iOS app.
This action can be built in its most straightforward version using the integrated Composer within LCP, but the way I’ve built it adds not only the Dropbox functionality, but also a couple of other interesting, if minimal, tweaks not natively available in the composer’s actions.
Take a quick look at the syntax of the action below, and then we’ll briefly discuss how it works…
Now, I’m going to assume that if you’re here reading this, you have at least the most basic knowledge of LCP’s URL scheme, so I’ll only explain what I’ve done to modify the URL created by the LCP Composer.
By default, the LCP Composer gives you 3 fields in which to type your post’s Title, Tags, and Content. What I’ve done with the [prompt:...] entries is to open a dialog each time the action is run instead of always using a static entry for each field. Furthermore, in the content field, I’ve not only used the Dropbox prompt, which prompts the user to select a file from their Dropbox, but I’ve further modified it to look directly in the folder where I keep the text file versions of all of my blog posts. And yes, I do write all of my posts in Notepad before migrating them into my blog. I’ve also modified the Dropbox prompt from the normal: [dropbox] to a more blog-friendly:[dropbox-text], which inserts the actual text within the selected file into the content area of the post instead of merely inserting a download link to the file.
Finally, you’ve probably noticed the: “&lc-icon=wordpress” at the very end after the last bracket. All this neat little snippet does is to force LCP to use the default WordPress icon as the icon for this action.
There you have it Twitches, just copy and paste that action URL into a new LCP action, change the dropbox directory to wherever within Dropbox you keep your text posts and Boom! you’re good to go.
Hit me up on Twitter if you have any comments, questions or suggestions.