Linux 软件免费装
Banner图

Marklane - Fast Publishing from Markdown.

开发者 cck23
更新时间 2026年5月9日 23:02
PHP版本: 8.0 及以上
WordPress版本: 6.9
版权: GPLv2 or later
版权网址: 版权信息

标签

import markdown importer yaml frontmatter

下载

1.4.5 1.4.6 1.4.4 1.4.7 1.4.8

详情介绍:

Marklane is built for fast publishing from Markdown. It helps editors turn local Markdown drafts into WordPress posts without copying content into the post editor by hand. Write locally in Markdown, add YAML frontmatter for post settings, then import the file from Tools > Marklane. Marklane can create a new post or update an existing one by slug, apply categories, tags, dates, featured images, post status, and Polylang language links in one import. When frontmatter is omitted, it can derive a draft title and slug from the first H1 and filename. If you enable Ignore invalid frontmatter, the plugin ignores only the invalid frontmatter keys and keeps the valid ones. If the YAML block itself is broken, it falls back to the filename and first H1 while keeping the selected post status and date options. Plugin page: https://happas.jp/marklane/ Features: For the most predictable image resolution behavior, it is recommended to disable WordPress's year/month based upload folders and to use fully unique filenames for Markdown files and image assets. This plugin is best suited to workflows where: Frontmatter quick reference: Marklane reads YAML frontmatter at the top of the Markdown file. Common keys include: title falls back to the first H1 and then the filename. slug falls back to the filename. postType defaults to post, and status defaults to draft. For more frontmatter examples: https://happas.jp/en/marklane/#yaml-frontmatter-example Known limitations:

安装:

  1. In the WordPress admin screen, go to Plugins > Add New.
  2. Search for Marklane.
  3. Click Install Now, then activate the plugin.
  4. Open Tools > Marklane.
  5. Upload a Markdown file or select one from the Media Library.
  6. Run a dry run to preview the result.
  7. Run the import to create or update the post.
If you prefer manual installation, upload the plugin folder to /wp-content/plugins/ and activate it from the Plugins screen.

常见问题:

What can I set with frontmatter?

You can set values such as:

  • title
  • slug
  • postType
  • excerpt
  • status
  • date
  • category
  • tags
  • featuredImage
  • lang
  • translations
postType defaults to post. Public registered post types are allowed by default, except attachments. Site-specific overrides can be applied with the marklane_whitelist filter. If title is omitted, Marklane uses the first H1 and then the filename. If slug is omitted, Marklane derives it from the filename.

Can it update an existing post?

Yes. The plugin matches an existing post by slug + post_type, or by slug + post_type + lang when Polylang is in use.

What does Dry Run show?

Dry Run shows the planned action before saving anything, including:

  • whether the import will create a new post or update an existing one
  • which existing post was matched
  • taxonomy assignment results
  • relative image and featuredImage resolution
  • warnings and errors raised during the import

How are images resolved?

Relative image paths are resolved against Media Library images in the same directory as the selected Markdown attachment. When Markdown and supporting images are uploaded together, the supporting images are stored as flat Media Library files, so nested folder paths are not preserved. The featuredImage frontmatter field follows the same rule and sets the post thumbnail when the target image is already registered in the Media Library. If FIFU is active, featuredImage can also point to an external URL. For more predictable results, use fully unique filenames and, if possible, disable WordPress's year/month based upload folders before uploading the Markdown file and related images.

Can I enable Japanese strong-emphasis compatibility behavior?

Yes. Marklane keeps league/commonmark as the Markdown converter and uses strict CommonMark behavior by default. If your Japanese writing workflow needs text such as **「text」**続き to render as strong text, enable the CJK compatibility pass: add_filter('marklane_enable_markdown_compatibility_preprocessing', '__return_true'); Advanced sites can replace the matching pattern with the marklane_markdown_compatibility_strong_boundary_pattern filter. For example, use a custom pattern for Japanese quoted text followed by a letter or number.

Does it work with Polylang?

Yes. When Polylang is active, you can use lang and translations in frontmatter to connect translated posts.

更新日志:

1.4.8 1.4.7 1.4.6 1.4.5 1.4.4 1.4.3 1.4.2 1.4.1 1.4.0 1.3.1 1.3.0 1.2.0 1.1.0 1.0.2 1.0.1 1.0.0 0.1.6 0.1.5 0.1.4 0.1.2 0.1.1 0.1.0