canonical-urls
3 months ago
carousel
3 weeks ago
comment-likes
7 months ago
comments
1 month ago
custom-post-types
6 days ago
external-media
7 months ago
google-fonts
6 days ago
gravatar
6 years ago
infinite-scroll
6 days ago
likes
6 days ago
markdown
1 month ago
memberships
6 days ago
photon-cdn
6 days ago
plugin-search
1 month ago
post-by-email
7 months ago
related-posts
4 weeks ago
scan
3 months ago
seo-tools
6 days ago
sharedaddy
3 weeks ago
shortcodes
6 days ago
shortlinks
1 month ago
simple-payments
7 months ago
site-icon
7 months ago
sitemaps
1 month ago
stats
6 months ago
subscriptions
6 days ago
theme-tools
6 days ago
tiled-gallery
3 weeks ago
verification-tools
1 month ago
videopress
6 days ago
widget-visibility
1 month ago
widgets
6 days ago
woocommerce-analytics
2 months ago
wordads
6 days ago
wpcom-tos
6 months ago
account-protection.php
2 months ago
blaze.php
7 months ago
blocks.php
7 months ago
canonical-urls.php
4 months ago
carousel.php
7 months ago
comment-likes.php
7 months ago
comments.php
3 months ago
contact-form.php
7 months ago
copy-post.php
1 month ago
custom-content-types.php
2 months ago
google-fonts.php
2 months ago
gravatar-hovercards.php
1 month ago
infinite-scroll.php
7 months ago
json-api.php
7 months ago
latex.php
1 month ago
likes.php
1 month ago
markdown.php
7 months ago
module-extras.php
7 months ago
module-headings.php
6 days ago
module-info.php
4 months ago
monitor.php
4 weeks ago
notes.php
6 days ago
photon-cdn.php
7 months ago
photon.php
7 months ago
plugin-search.php
6 days ago
post-by-email.php
2 months ago
post-list.php
7 months ago
protect.php
2 months ago
publicize.php
7 months ago
related-posts.php
1 month ago
search.php
7 months ago
seo-tools.php
6 days ago
sharedaddy.php
4 months ago
shortcodes.php
7 months ago
shortlinks.php
1 month ago
simple-payments.php
7 months ago
sitemaps.php
7 months ago
sso.php
6 days ago
stats.php
1 month ago
subscriptions.php
6 days ago
theme-tools.php
7 months ago
tiled-gallery.php
7 months ago
vaultpress.php
7 months ago
verification-tools.php
2 months ago
videopress.php
7 months ago
waf.php
7 months ago
widget-visibility.php
7 months ago
widgets.php
7 months ago
woocommerce-analytics.php
7 months ago
wordads.php
7 months ago
wpcom-reader.php
4 months ago
wpgroho.js
1 year ago
markdown.php
36 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Module Name: Markdown |
| 4 | * Module Description: Write and format posts using clean, readable Markdown syntax. |
| 5 | * Sort Order: 31 |
| 6 | * First Introduced: 2.8 |
| 7 | * Requires Connection: No |
| 8 | * Auto Activate: No |
| 9 | * Module Tags: Writing |
| 10 | * Feature: Writing |
| 11 | * Additional Search Queries: md, markdown |
| 12 | * |
| 13 | * @package automattic/jetpack |
| 14 | */ |
| 15 | |
| 16 | if ( ! defined( 'ABSPATH' ) ) { |
| 17 | exit( 0 ); |
| 18 | } |
| 19 | |
| 20 | // Require the markdown class file. |
| 21 | require __DIR__ . '/markdown/easy-markdown.php'; |
| 22 | |
| 23 | /** |
| 24 | * Remove checkbox set in modules/markdown/easy-markdown.php. |
| 25 | * We don't just remove the register_setting call there because the checkbox is |
| 26 | * needed on WordPress.com, where the file is sync'ed verbatim. |
| 27 | */ |
| 28 | function jetpack_markdown_posting_always_on() { |
| 29 | // why oh why isn't there a remove_settings_field? |
| 30 | global $wp_settings_fields; |
| 31 | if ( isset( $wp_settings_fields['writing']['default'][ WPCom_Markdown::POST_OPTION ] ) ) { |
| 32 | unset( $wp_settings_fields['writing']['default'][ WPCom_Markdown::POST_OPTION ] ); |
| 33 | } |
| 34 | } |
| 35 | add_action( 'admin_init', 'jetpack_markdown_posting_always_on', 11 ); |
| 36 |