[WordPress] 外掛分享: Etsy Importer

首頁外掛目錄 › Etsy Importer
⚠ 此外掛已下架 — 不再更新維護,建議勿安裝。
100+
安裝啟用
★★★★
4/5 分(12 則評價)
1129 天前
最後更新
問題解決
WordPress 3.5+ v1.4.2 上架:2013-12-31

內容簡介

此外掛提供了將 Etsy 商店庫存全數匯入 WordPress 內,以產品客製化文章形式(post)呈現。只需提供 Etsy 應用程式的 API 金鑰和商店 ID,此外掛會替您完成其餘的步驟。

Etsy 匯入器(Etsy Importer)不僅會匯入您的產品,還會:

將所有產品圖像附加於文章上
將主要產品圖像設定為文章的特色縮略圖
新增並附加到您的產品的任何類別(category)
新增並附加到您的產品的任何標籤(tag)
添加 Etsy 產品列表 ID、價格、Etsy 產品連結、製造年度和為男性/女性生產的(meta)資訊至文章中。
每天自動檢查 Etsy 商店中的新產品,並在每天匯入。完全零負擔。
檢查在您的商店中不存在的現有帖子作為活躍產品,並將其設置為草稿帖子狀態。

本插件不僅匯入您的產品,還添加了一些快捷代碼以幫助您整合產品到網誌文章中。

迅速代碼(Shortcodes)

顯示指向您的產品鏈接,作為連結使用文章標題來顯示:

[product_link id=569]

或者作為指向 Etsy 產品頁面的外部連結:

[product_link id=569 title=”This is a great new product” external=true]

顯示您的產品帖子內容縮短為您想要的長度。如果未為長度設定任何值,則將顯示原帖子的全部內容:

[product_content id=569 length=50]

使用 WordPress 內建的 Thickbox jQuery 和 CSS 在一個Thickbox 輪廓中顯示您的產品圖像:

[product_images id=569]

Etsy 匯入器(Etsy Importer)允許您在文章進行過程中過濾內容。以下列出了可用的過濾器及其修改方式和功能。

etsy_importer_default_post_status
您的帖子本身的默認帖子狀態,當正在匯入的產品目前處於活動狀態時。

使用 :

function your_project_modify_etsy_importer_default_post_status() {
return 'publish';
}
add_filter( 'etsy_importer_default_post_status', 'your_project_modify_etsy_importer_default_post_status' );

etsy_importer_updated_post_status
當相應的產品當前為非活動狀態時,現有帖子所設置的帖子狀態儀器。

使用 :

function your_project_modify_etsy_importer_updated_post_status() {
return 'draft';
}
add_filter( 'etsy_importer_updated_post_status', 'your_project_modify_etsy_importer_updated_post_status' );

etsy_importer_updated_post_args

在匯入產品時更新帖子的帖子引數(post arguments)。

使用 :

function your_project_modify_etsy_importer_updated_post_args( $post_args ) {
// Always set the post with the ID 45 to publish
if( 45 == $post_args[ID] ) {
$post_args[post_status] = 'publish';
}

return $post_args;
}
add_filter( 'etsy_importer_updated_post_args', 'your_project_modify_etsy_importer_updated_post_args' );

etsy_importer_custom_post_type_key

自訂文章類型鍵。

使用 :

function your_project_modify_etsy_importer_custom_post_type_key() {
return 'my_products';
}
add_filter( 'etsy_importer_custom_post_type_key', 'your_project_modify_etsy_importer_custom_post_type_key' );

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.4.2) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Etsy Importer」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

This plugin will allow you to import your entire Etsy shop’s inventory into WordPress as posts in a Products custom post type. All you have to do is supply an API Key for an Etsy application and the ID of your shop and the plugin will do the rest.
The Etsy Importer will not only import your products but will also:

Attach all of the product’s images to the post
Set the main product image as the post’s featured thumbnail
Add and attach any category added to your product
Add and attach any tag added to your product
Add the Etsy Product Listing ID, Price, Etsy Product Link, Production Year, and Made For (men/women) meta information to the post
Check for new products in your Etsy shop daily and import them automatically once daily. Hands free!
Check for existing posts which no longer exist in your shop as active products and set them to draft post status

Not only do we import your products, but we add some shortcodes to help you integrate your products into blog posts.
Shortcodes
Display a link to your product – either as a link to the post within your site using the post title as the link text:
[product_link id=569]
[product_link id=569 title=”This is a great new product”]
Or as an external link to your Etsy product page:
[product_link id=569 title=”This is a great new product” external=true]
Display your product’s post content trimmed to whatever length you wish. If no value is set for the length, the full content of the post will be displayed:
[product_content id=569 length=50]
Display your product’s images in a Thickbox gallery using WordPress’ built-in Thickbox jQuery and CSS:
[product_images id=569]
The Etsy Importer allows for the filtering of content throughout the course of posts being imported. Below are the filters available, with details on what they do and how they can be modified.
etsy_importer_default_post_status
The default post status your post will be set to when a product being imported is currently ACTIVE.
Usage:
function your_project_modify_etsy_importer_default_post_status() {
return 'publish';
}
add_filter( 'etsy_importer_default_post_status', 'your_project_modify_etsy_importer_default_post_status' );

etsy_importer_updated_post_status
The post status your existing post will be set to when its corresponding product is currently NOT ACTIVE.
Usage:
function your_project_modify_etsy_importer_updated_post_status() {
return 'draft';
}
add_filter( 'etsy_importer_updated_post_status', 'your_project_modify_etsy_importer_updated_post_status' );

etsy_importer_updated_post_args
The post arguments passed to update posts when importing products.
Usage:
function your_project_modify_etsy_importer_updated_post_args( $post_args ) {
// Always set the post with the ID 45 to publish
if( 45 == $post_args[ID] ) {
$post_args[post_status] = 'publish';
}

return $post_args;
}
add_filter( 'etsy_importer_updated_post_args', 'your_project_modify_etsy_importer_updated_post_args' );

etsy_importer_custom_post_type_key
The custom post type key.
Usage:
function your_project_modify_etsy_importer_custom_post_type_key() {
return 'my_products';
}
add_filter( 'etsy_importer_custom_post_type_key', 'your_project_modify_etsy_importer_custom_post_type_key' );

etsy_importer_category_key
The custom post type’s Category key.
Usage:
function your_project_modify_etsy_importer_category_key() {
return 'my_category';
}
add_filter( 'etsy_importer_category_key', 'your_project_modify_etsy_importer_category_key' );

etsy_importer_tag_key
The custom post type’s Tag key.
Usage:
function your_project_modify_etsy_importer_tag_key() {
return 'my_tag';
}
add_filter( 'etsy_importer_tag_key', 'your_project_modify_etsy_importer_tag_key' );

etsy_importer_product_link_shortcode
Filter the output of the product link shortcode.
Usage:
function your_project_modify_etsy_importer_product_link_shortcode( $output, $atts ) {
// Output a custom value based on the post ID
if ( 4439 == $atts['id'] ) {

$output = 'This is my custom output for post ID 4439';

}

// Return the output
return $output;

}
add_filter( 'etsy_importer_product_link_shortcode', 'your_project_modify_etsy_importer_product_link_shortcode', 10, 2 );

etsy_importer_product_content_shortcode
Filter the output of the product content shortcode.
Usage:
function your_project_modify_etsy_importer_product_content_shortcode( $output, $atts ) {
// Output a custom value based on the post ID
if ( 4439 == $atts['id'] ) {

$output = 'This is my custom output for post ID 4439';

}

// Return the output
return $output;

}
add_filter( 'etsy_importer_product_content_shortcode', 'your_project_modify_etsy_importer_product_content_shortcode', 10, 2 );

etsy_importer_product_images_shortcode_args
Filter the args passed when displaying a product’s images.
Usage:
function your_project_modify_etsy_importer_product_images_shortcode_args( $args ) {
// Limit the number of images displayed to 1
$args['posts_per_page'] = 1;

// Return the args
return $args;

}
add_filter( 'etsy_importer_product_images_shortcode_args', 'your_project_modify_etsy_importer_product_images_shortcode_args' );

etsy_importer_product_images_shortcode_thumb_size
Filter the size of the thumbnail iamge shown when displaying a product’s images.
Usage:
function your_project_modify_etsy_importer_product_images_shortcode_thumb_size( $atts ) {
// Use the 'large' image size to display images
return 'large';

}
add_filter( 'etsy_importer_product_images_shortcode_thumb_size', 'your_project_modify_etsy_importer_product_images_shortcode_thumb_size' );

etsy_importer_product_images_shortcode
Filter the output of the product images shortcode.
Usage:
function your_project_modify_etsy_importer_product_images_shortcode( $output, $atts ) {
// Display a different output based on post ID
if ( 4439 == $atts['id'] ) {
$output = 'Visit my Etsy shop to view my images.';
}

// Return the output
return $output;

}
add_filter( 'etsy_importer_product_images_shortcode', 'your_project_modify_etsy_importer_product_images_shortcode', 10, 2 );

etsy_importer_product_import_insert_args
Filter the arguments passed when importing your products.
Usage:
function your_project_modify_etsy_importer_product_import_insert_args( $args, $product ) {
// Filter the post arguments used when importing your posts
// In this example, we are adding "My product: " to the beginning of the post title
$args['post_title'] = 'My product: ' . esc_html( $product->title );

// Return the output
return $args;

}
add_filter( 'etsy_importer_product_import_insert_args', 'your_project_modify_etsy_importer_product_import_insert_args', 10, 2 );

延伸相關外掛

文章
Filter
Apply Filters
Mastodon