內容簡介
Missing content 外掛提供多個不同內容的選擇,如果您需要其他內容,請發佈到支援論壇中請求。
內容選擇
Loreum Ipsum,從http://loripsum.net/
Bacon Ipsum,從http://baconipsum.com/api/
Hipster Ipsum,從http://hipsterjesus.com/
Blokk 字型,從http://blokkfont.com/
圖像,從http://placehold.it
如何使用?
在文章編輯器中使用短碼 [missing-content] 或在模板中使用函式mcn_missing_content( $atts, $echo = true ).
選項
content_type=”lipsum” 值: lipsum|hipster|bacon|blokk|image
paragraph_count=”3″ 如果 random=”true”,則忽略此項。
min_paragraph_count=”1″ 需要 random=”true”。
max_paragraph_count=”5″ 需要 random=”true”。
width=”150″ 如果 random=”true”,則忽略此項。
min_width=”150″ 需要 random=”true” 且 content_type=”image”。
max_width=”1200″ 需要 random=”true” 且 content_type=”image”。
height=”150″ 如果 random=”true”,則忽略此項。
min_height=”150″ 需要 random=”true” 且 content_type=”image”。
max_height=”1200″ 需要 random=”true” 且 content_type=”image”。
random=”false” 值: (shortcode: “true”|”false”) (function: true|false)
cache_duration=”10800″ 3 小時 (3 * 60 * 60) 值: {秒數}|always|never
範例
[missing-content] 從http://loripsum.net/取得 3 段落的內容,每 3 小時更新一次。
[missing-content cache_duration="always"] 不更新內容。
[missing-content cache_duration="never"] 從http://loripsum.net/取得 3 段落的內容,每次刷新頁面時更新。注意:如果使用像是 LiveReload 的工具就不要使用此功能。
[missing-content paragraph_count="1" cache_duration="86400"] 每天顯示更新一次的 1 段落內容(24 * 60 * 60)。
[missing-content content_type="bacon" paragraph_count="5"] 從http://baconipsum.com/api/取得 5 段落的內容,每 3 小時更新一次。
[missing-content content_type="hipster"] 從http://hipsterjesus.com/取得 3 段落的內容,每 3 小時更新一次。
[missing-content content_type="blokk"] 使用http://blokkfont.com/的 Blokk 字型取得 3 段落的內容,每 3 小時更新一次。
[missing-content content_type="image" width="500" height="500"] 從http://placehold.it取得 500px x 500px的圖像。注意:沒有快取控制。
[missing-content content_type=”image” random=”true” min_width=”150″ max_width=”500″ min_height=”150″ max_height=R
外掛標籤
開發者團隊
原文外掛簡介
Missing content offers multiple different content choices, if you would like to request something else please post it to the support forums.
Content Choices
Loreum Ipsum from http://loripsum.net/
Bacon Ipsum from http://baconipsum.com/api/
Hipster Ipsum from http://hipsterjesus.com/
Blokk Font http://blokkfont.com/
Image from http://placehold.it
How do I use it?
Either with the shortcode [missing-content] in the post editor or with the function mcn_missing_content( $atts, $echo = true ) in your template.
Options
content_type=”lipsum” options: lipsum|hipster|bacon|blokk|image
paragraph_count=”3″ Ignored if random=”true”
min_paragraph_count=”1″ Requires random=”true”
max_paragraph_count=”5″ Requires random=”true”
width=”150″ Ignored if random=”true”
min_width=”150″ Requires random=”true” and content_type=”image”
max_width=”1200″ Requires random=”true” and content_type=”image”
height=”150″ Ignored if random=”true”
min_height=”150″ Requires random=”true” and content_type=”image”
max_height=”1200″ Requires random=”true” and content_type=”image”
random=”false” options: (shortcode: “true”|”false”) (function: true|false)
cache_duration=”10800″ 3 hours (3 * 60 * 60) options: {time in seconds}|always|never
Examples
[missing-content] 3 paragraphs from http://loripsum.net/ updated every 3 hours.
[missing-content cache_duration="always"] Never updates the content.
[missing-content cache_duration="never"] 3 paragraphs from http://loripsum.net/ updated every page refresh. NOTE: do not use this if using a tool like LiveReload.
[missing-content paragraph_count="1" cache_duration="86400"] Displays one paragraph updated every day (24 * 60 * 60).
[missing-content content_type="bacon" paragraph_count="5"] 5 paragraphs from http://baconipsum.com/api/ updated every 3 hours.
[missing-content content_type="hipster"] 3 paragraphs from http://hipsterjesus.com/ updated every 3 hours.
[missing-content content_type="blokk"] 3 paragraphs of Blokk font using http://blokkfont.com/ updated every 3 hours.
[missing-content content_type="image" width="500" height="500"] 500px x 500px image from http://placehold.it NOTE: no cache control.
[missing-content content_type=”image” random=”true” min_width=”150″ max_width=”500″ min_height=”150″ max_height=”300″] Random sized image 150px – 500px wide and 150px – 300px high.
[missing-content random=”true” min_paragraph_count=”1″ max_paragraph_count=”5″] 1-5 paragraphs from a random content source.
More examples can be found here
