內容簡介
將維基百科摘錄添加到您的頁面中,作為小部件,可在內容上方或下方添加,或在任何您想要的地方使用 shortcode。
要將維基標題和內容連接到您的文章中,文章編輯頁面上有一個帶有3個選項卡的小工具。
第一個默認選項卡只是讓您在上面的輸入欄中開始輸入。當您停止輸入幾秒鐘時,會顯示一個發現的資料列表。
當與geo2wp(我另一個外掛)或任何其他添加坐標到文章的外掛一起使用時,將會出現第二個地理選項卡。進入其頁面,將顯示由位置距離排序的找到的對象列表。
第三個選項卡將顯示找到的維基內容的預覽。
選擇您要的內容和更新。
一旦將維基頁面連接到文章,還有幾種方法可以在您的網站上顯示這些內容:
首先,您可以添加僅在有可顯示內容時顯示的小工具。
然後,您可以在設置中打開開關,將信息添加為區塊引用,展示在內容的上方或下方。
最後,有一個四個選項的shortcode [wiki]:
[wiki]或[wiki part=extract]用於顯示摘錄內容
[wiki part=title]用於僅顯示標題
[wiki part=url]顯示'原始' URL,指向維基百科頁面
[wiki part=link]顯示相關信息填充的完整連結。
geo2wp有一個開關,可以啟用在小工具中使用shortcode的功能,請隨意嘗試。
警告:
目前,所有操作和 URL 都基於在設置屏幕中選擇的語言。這個語言默認是在啟用插件時的網站語言。如果您稍後更改語言,则維基百科的 URL 可能無法正常工作,因為標題將不同。
目前,我正在考慮兩種解決方案:將使用的語言存儲在wikiData中,以便始終知道語言或使 wikiData 語言依賴。當您選擇其他語言時,所有內容都會被清空,但當您返回時,內容將恢復。歡迎提出意見。
至於設置屏幕中的其他設置:
最大結果:搜索時返回的最大結果數
最大搜索半徑:搜尋地理位置的半徑(米)
將維基內容添加到內容中:none | top | below
在內容中顯示 wikiData blockquote 的位置。默認值為none。
使用的jQuery-ui主題。默認值為'flick',但可用於'https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/themes/'下的任何其他主題。
外掛標籤
開發者團隊
原文外掛簡介
Add wikipedia extracts to your page as a widgid, above or under your content or using shortcode’s wherever you like.
To connect a wikipedia title and extact to your post, there’s a widget on the post edit page with 3 tabs.
The first, default, tab just tells you to start typing in the inputfield above. A datalist with finds will show
up when you stop typing for a few seconds.
When used with geo2wp, on of my other plugins, or with any other plugin which adds coordinates to a post, a second
Geo tab will be available. Select it and a list of found objects, sorted by distance from the location, will be shown.
The third tab will give you a preview of the found wikipedia info.
Make your pick and update.
Once a wikipedia page is linked to the post, there are also a number of ways to show the info on your site:
First you can add a widget which is only shown when there’s something to show.
Then you can turn on the switch in the settings for adding the information as a blockquote above or
below the content.
And lastly there’s a shortcode [wiki] with four options:
[wiki] or [wiki part=extract] to show the extract
[wiki part=title] to show only the title
[wiki part=url] to show the ‘raw” url which refers to the wikipedia page
[wiki part=link] to show a full with the relevant info filled.
geo2wp has a switch to enable the use of shortcodes in widgets so hack away.
Warning:
At this moment all the actions and urls are based on the language selected in the settingsscreen. This language
is by default the language of the site at the time of activating the plugin. If you change the language on a later
time, it is very possible that the urls to wikipedia will no longer work as the titles will be different.
For now I’m pondering two solutions: To store the used language in the wikiData so the language is always know, OR,
to make the wikiData language depending. When you select an other language, everything will be gone, but when your
go back it will be there again. Opinions are welcome..
As for the other settings in the settingsscreen:
Max. results: The maximal number of results to give back when searching
Max. search radius: The radius in meters in where to search geographical
Add the wikipedia info to the content: none | top | below
Where to show the wikiData blockquote in the content. Default is none.
The jQuery-ui theme used. Default is “flick” but any other theme, available under
‘https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/themes/’ is usable.
