跳转到内容

Template:OpenSecrets/doc

维基百科,自由的百科全书

Template:OpenSecrets displays an external link to a page at OpenSecrets, a website that tracks and publishes data on campaign finance and lobbying. It is intended for use in the external links section of an article.

Usage

[编辑]
Unnamed parameters
{{OpenSecrets | user name or number }}
{{OpenSecrets | user name or number | Displayed Name }}
Named parameters
{{OpenSecrets | id= user name or number }}
{{OpenSecrets | id= user name or number | name= Displayed Name }}
Using Wikidata property
{{OpenSecrets}}
{{OpenSecrets | name= Displayed Name }}

Examples

[编辑]

Linking to a profile or page

[编辑]

In this example, the OpenSecrets ID is d000067823 and the link text is Alphabet Inc.:

https://www.opensecrets.org/orgs/summary?id=d000067823
* {{OpenSecrets | d000067823 | Alphabet Inc. }}

Using Wikidata

[编辑]

Generally, Wikidata should contain article subjects' OpenSecrets IDs in property 無本頁之數據, allowing the ID parameter to be omitted:

* {{OpenSecrets}}
* {{OpenSecrets |name=NAME }}

If the Wikidata property is not defined, the output is:

  • {{OpenSecrets}} template missing ID and not present in Wikidata.

TemplateData

[编辑]
以下是该模板的模板数据,适用于可视化编辑器等工具。

OpenSecrets模板数据

Generate a link to a OpenSecrets profile in a standard format.

模板参数

参数描述类型状态
Account IDid 1

ID of the OpenSecrets account (part of the web page address, for www.OpenSecrets.com/example/ the account id is "example"). This parameter is optional if Wikidata property P4691 exists, but required if not.

默认值
Wikidata property P4691
示例值
d000067823
单行文本可选
Display namename 2

Display name for the OpenSecrets account

默认值
Name of the page
示例值
Alphabet Inc.
单行文本可选

See also

[编辑]