Custom Press This - Pixel Envy


Nick Heer (another Calgarian WordPress user!) posted a modified WordPress press-this.php file to enable Markdown syntax: Custom "Press This" — Pixel Envy.

custom press-this.php file has been updated to work with WordPress 3.4.

It really just modifies the core WordPress wp-admin/press-this.php file to use Markdown syntax, rather than raw HTML. Not elegant, and will need to be updated if that file changes in future versions of WordPress. But it works, and that's all that counts.

What it does is around line 600, changing the $content string that's pushed to the editor:

$content = '';
if ( $url ) 
    $content .= sprintf( "via [%s](%s).\n\n", esc_html( $title ), esc_url( $url ) );
if ( $selection ) {
    $content .=  $selection;
}

Easy peasy. Now, to try modifying it some more, so the great Markdown QuickTags plugin can do its thing on the Press This editor...


See Also

comments powered by Disqus