[WordPress] 外掛分享: CSV Importer Improved

WordPress 外掛 CSV Importer Improved 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「CSV Importer Improved」是 2015-12-16 上架。
  • 目前有 200 個安裝啟用數。
  • 上一次更新是 2016-10-10,距離現在已有 3128 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
  • 外掛最低要求 WordPress 3.0.0 以上版本才可以安裝。
  • 有 5 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

judgej |

外掛標籤

csv | batch | excel | import | spreadsheet |

內容簡介

這個 WordPress 外掛可將 CSV(逗號分隔值)檔案中的文章匯入到您的WordPress部落格中。當您需要從Excel文件或類似文件匯入一堆文章時,它非常有用,只需將文件匯出為CSV檔案,外掛就會為您處理其餘部分。

CSV Importer Improved

功能

匯入文章標題、內容、摘要、標籤、日期、類別等。
支援自訂欄位、自訂分類和評論。
使用 WordPress 內建機制處理 Word 樣式引號和其他非標準字符(與您編寫文章時正規化輸入的方式相同)。
CSV檔案中的列可以是任何順序,只要它們有正確的標題即可。
支援多語言。

此外掛是從 dvkob 的 https://wordpress.org/plugins/csv-importer/ 中衍生出來,以跟上 WordPress 核心的變化。

此匯入程式直接寫入資料庫,不會通過內部 WordPress 物件創建文章等。這可能是一個優點(對於大型匯入來說速度更快),但也要注意可能會出現的任何數據完整性問題。

僅支援 UTF-8編碼,帶有或不帶有順序標記(BOM)。

此外掛的開發存儲庫在以下位置:

https://github.com/academe/csv-importer-improved

請隨意在那裡提出問題和提交拉取請求,以及通過常規的WordPress渠道。

使用方法

在 WordPress 管理頁面上點擊 CSV 匯入器鏈接,選擇您要匯入的檔案,然後點擊匯入。外掛目錄內的 examples 目錄包含幾個演示如何使用外掛的檔案。入門的最佳方式是導入其中一個檔案並查看結果。

CSV是一種表格格式,由行和列組成。CSV檔案中的每一行表示一篇文章。每個欄位則識別了構成該篇文章的一個資訊塊。

您可以通過提供指向現有文章的csv_post_id欄位來創建新文章或更新現有文章。進行更新時,您在CSV文件中提供的所有欄位名稱都將更新,即使是空白的欄位也會更新,但您在CSV文件頭部未列出的欄位將保持不變。

基本的文章資訊

csv_post_id(可選)- 用於更新現有文章。
csv_post_title - 文章標題。
csv_post_post - 文章內容。
csv_post_type - post、page 或自訂文章類型。從0.3.2起,csv_post_type欄位支援自訂文章類型。
有關如何設置自訂文章類型,請參閱 WordPress 的自訂文章類型的說明文檔。
csv_post_excerpt - 文章摘要。
csv_post_categories - 類別名稱或id的逗號分隔清單。
名稱清單必須用引號括起來,例如"EC> UK,Island"。
如果不存在子類別鏈,例如“Animalia> Chordata> Mammalia”,則會創建它們,並將文章分配給鏈的末尾。
還可以使用其id定義父級類別,例如

原文外掛簡介

This WordPress plugin imports posts from CSV (Comma Separated Value) files into your
WordPress blog. It can prove extremely useful when you want to import a bunch
of posts from an Excel document or the like – simply export your document into
a CSV file and the plugin will take care of the rest.

CSV Importer Improved


Features

Imports post title, body, excerpt, tags, date, categories etc.
Supports custom fields, custom taxonomies and comments
Deals with Word-style quotes and other non-standard characters using
WordPress’ built-in mechanism (same one that normalizes your input when you
write your posts)
Columns in the CSV file can be in any order, provided that they have correct
headings
Multi-language support

This plugin is forked from https://wordpress.org/plugins/csv-importer/ by dvkob
in order to keep up with changes to the core WordPress.
This importer writes directly to the database. It does not go through the internal
WordPress objects for creating posts etc. That may be an advantage to you (it will
be faster for large imports) but do be aware of any data integrity issues that may arrise.
Only UTF-8 encoding is supported, both with and without Byte Order Marks (BOM).
The development repository for this plugin can be found here:
https://github.com/academe/csv-importer-improved
Please feel free to raise issues there, and submit pull requests, as well as through
the normal WordPress channels.
Usage
Click on the CSV Importer link on your WordPress admin page, choose the
file you would like to import and click Import. The examples directory
inside the plugin’s directory contains several files that demonstrate
how to use the plugin. The best way to get started is to import one of
these files and look at the results.
CSV is a tabular format that consists of rows and columns. Each row in
a CSV file represents a post; each column identifies a piece of information
that comprises a post.
You can create new posts, or update existing posts by supplying the csv_post_id
field pointing to an existing post. When updating, all field names you provide
in the CSV file will be updated – even if blank – but fields you don’t list at
the head of the CSV file will be left intact.
Basic post information

csv_post_id – optional, used to update an existing post.
csv_post_title – title of the post
csv_post_post – body of the post
csv_post_type – post, page or a custom post type.
From 0.3.2, csv_post_type column supports custom post types.
Refer to the WordPress
documentation on custom post types for more info
on how to set up custom post types.
csv_post_excerpt – post excerpt
csv_post_categories – a comma separated list of category names or ids.
The list must be enclosed in quotes, e.g. “EC > UK, Island”.
If a chain of subcategories does not exist, e.g. Animalia > Chordata > Mammalia
then they will all be created and the post assigned to the end of the chain.
The parent category can also be defined using its id, e.g.
42 > Primates > Callitrichidae, where 42 is an
existing category id.
csv_post_tags – a “quoted” comma separated list of tags.
csv_post_date – most standard formats are supported.
For example, now, 11/16/2009 0:00, 1999-12-31 23:55:00, +1 week,
next Thursday, last year are all valid. For technical
details, consult PHP’s strtotime() function documentation.

Custom fields
Any column that doesn’t start with csv_ is considered to be a custom field
name. The data in that column will be imported as the custom fields value.
All custom fields must be unique. Multiple fields with the same name will be
updated to the same value if updating an existing post.
Prior to version 0.6.0 loading the same field name multiple times to an existing
post would create multiple custom fields.
General remarks

WordPress pages don’t have categories or tags.
Most columns are optional. Either csv_post_title, csv_post_post or
csv_post_excerpt are sufficient to create a post. If all of these
columns are empty in a row, the plugin will skip that row.
The plugin will attempt to reuse existing categories or tags; if an
existing category or tag cannot be found, the plugin will create it.
To specify a category that has a greater than sign (>) in the name, use
the HTML entity >

Advanced usage

csv_post_author – numeric user id or login name. If not specified or
user does not exist, the plugin will assign the posts to the user
performing the import.
csv_post_slug – post slug used in permalinks.
csv_post_parent – post parent id.

Custom taxonomies
New in version 0.3.0
Once custom taxonomies are set up in your theme’s functions.php file or
by using a 3rd party plugin, csv_ctax_(taxonomy name) columns can be
used to assign imported data to the taxonomies.
Non-hierarchical taxonomies
The syntax for non-hierarchical taxonomies is straightforward and is essentially
the same as the csv_post_tags syntax.
Hierarchical taxonomies
The syntax for hierarchical taxonomies is more complicated. Each hierarchical
taxonomy field is a tiny two-column CSV file, where the order of columns
matters. The first column contains the name of the parent term and the second
column contains the name of the child term. Top level terms have to be preceded
either by an empty string or a 0 (zero).
Sample examples/custom-taxonomies.csv file included with the plugin
illustrates custom taxonomy support. To see how it works, make sure to set up
custom taxonomies from functions.inc.php.
Make sure that the quotation marks used as text delimiters in csv_ctax_
columns are regular ASCII double quotes, not typographical quotes like “
(U+201C) and ” (U+201D).
Comments
New in version 0.3.1
An example file with comments is included in the examples directory.
In short, comments can be imported along with posts by specifying columns
such as csv_comment_*_author, csv_comment_*_content etc, where * is
a comment ID number. This ID doesn’t go into WordPress. It is only there
to have the connection information in the CSV file.
Credits
This plugin uses php-csv-parser by Kazuyoshi Tlacaelel.
It was inspired by JayBlogger’s CSV Import plugin.
Contributors:

Kevin Hagerty (post_author support)
Edir Pedro (root category option and tableless HTML markup)
Frank Loeffler (comments support)
Micah Gates (subcategory syntax)
David Hollander (deprecation warnings, linebreak handling)

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「CSV Importer Improved」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


0.4.2 | 0.5.0 | 0.5.2 | 0.5.4 | 0.6.0 | 0.6.1 | trunk |

延伸相關外掛(你可能也想知道)

  • TablePress – Tables in WordPress made easy 》TablePress 是最受歡迎和評分最高的 WordPress 表格外掛程式。它允許您輕鬆地在您的網站上創建和管理美麗的表格。您可以使用區塊編輯器在文章、頁面或其他網...。
  • GravityExport Lite for Gravity Forms 》, GravityExport 是從 Gravity Forms 匯出資料的最佳、無需麻煩的解決方案。, GravityExport 提供強大的新功能!可將匯出儲存至 FTP 和 Dropbox、匯出為 PDF...。
  • Export User Data 》一個可以匯出 WordPress 使用者資料和元數據的外掛。, 包括匯出使用者身分、註冊日期範圍、使用者元選項和兩種匯出格式的選項。, 此外掛程式設計用來匯出儲存...。
  • Product Export for WooCommerce to CSV, Excel, XML, and the Google Merchant Center 》使用 WooCommerce 產品匯出外掛程式 WP All Export Add-On,可以匯出產品資訊為 CSV、Excel 或 XML 檔案。WP All Export 提供了選擇匯出的產品欄位,按需要重...。
  • ULTIMATE TABLES 》這個外掛讓你可以輕鬆地在 WordPress 管理頁面中創建和管理表格,你可以在頁面、文章、帖子或「ultimate tables widget」中插入表格。, 演示和外掛頁面, 它的...。
  • Simple CSV/XLS Exporter 》本外掛可以讓您透過簡單的連結/按鈕,從後端或前端匯出文章為 CSV 或 XLS 檔案。, 請確保您使用 PHP 7.3 或更新版本,如果您看到任何錯誤,舊版本將不再受支...。
  • CSV Importer 》此外掛可以將 CSV(逗號分隔值)檔案中的文章匯入 WordPress 網誌。當您要從 Excel 文件或類似文件匯入一堆文章時,這是非常有用的工具 - 只需將文件匯出成 C...。
  • WP CSV 》大多數 WordPress 功能都得到完整支援:, , 超過5萬行可以匯入/匯出(唯一的限制是您的伺服器), 文章、頁面和自訂文章類型, 標籤、分類和自訂稅目 , 自訂欄...。
  • WP CSV to Database – Insert CSV file content into WordPress database 》WP CSV to Database 外掛能夠讓你將 CSV 檔案內容插入 WordPress 資料庫,你可以選擇性地插入資料到特定的資料庫表格中。, 此外,你也能夠使用這個外掛匯出任...。
  • Docxpresso 》如果您習慣使用辦公室軟件,例如 MS Office、Libre Office 或 Open Office 的文字處理軟件或試算表,Docxpresso 是您一直在尋找的 WordPress 外掛!, , 此外...。
  • Import Spreadsheets from Microsoft Excel 》「從 Microsoft Excel 匯入試算表」是一款 WordPress 的外掛,它可以讓您將 Microsoft Excel 中的即時計算試算表匯入到 WordPress 的博客或網站中。該外掛是...。
  • Spreadsheet Price Changer for WooCommerce and WP E-commerce – Light 》這是一個針對 WooCommerce / WP E-commerce 產品價格和促銷價格的快速輸入試算表編輯器。, 這是著名的產品管理員/批量產品編輯器的免費簡化版本,僅允許更改...。
  • Easy Document Embedder – Embed Word, excel, Powerpoint, Pdf file and more.. 》透過在網站上嵌入文件是我們經常需要進行的常見事情。透過使用此外掛,您可以嵌入所有常見文件,如PDF、Word、XLS、PPT等等,這樣可以節省您的時間,並使您的...。
  • Spreadsheet Paste Block 》您可以直接從試算表 (例如 Google Sheets 或 LibreOffice Calc) 複製儲存格並貼到這個區塊。儲存格將會被正確地顯示和格式化。。
  • Export to Excel 》如果您能夠將您的部落格或網站匯出到 MS Excel,這將會非常方便,現在您可以使用 Export 2 Excel 來轉換您的數據成為本機 MS Excel 格式,並體驗真正的可攜性...。

文章
Filter
Apply Filters
Mastodon