Module talk:WikidataIB: Difference between revisions

Content deleted Content added
Coordinates: new section
 
Line 1:
{{Permanently protected}}
== Testing ==
{{WPBS|
{{WikiProject Wikidata}}
}}
{{banner holder|text=Page history|1=
{{oldtfdfull|date= 2020 September 15 |result=keep |disc=Module:Wikidata Infobox}}
}}
{{to-do|collapsed=yes}}
{{archives|search=yes}}
{{User:MiszaBot/config
|archiveheader = {{talkarchivenav}}
|maxarchivesize = 75K
|counter = 8
|minthreadsleft = 3
|minthreadstoarchive = 1
|algo = old(60d)
|archive = Module talk:WikidataIB/Archive %(counter)d
}}
 
==Multiple qualifiers==
Let's see how this would work in [[Animal farm]], [[d:Q1396889]].
Is there a way to filter a property with many values by two or more qualifiers? [[User:Serresmap|Serresmap]] ([[User talk:Serresmap|talk]]) 00:18, 10 April 2024 (UTC)
 
:@[[User:Serresmap|Serresmap]]: I don't think so. I recommend using [[Module:Wd]] instead, e.g. <code><nowiki>{{#invoke:wd|properties|Q55|P7295|P518=Q762943|P1365=Q11184}}</nowiki></code>. [[User:LennardHofmann|LennardHofmann]] ([[User talk:LennardHofmann|talk]]) 12:55, 12 April 2024 (UTC)
=== Local parameter ===
<pre>
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |Fred Bloggs}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages |name=author}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages; |name=author |Freda Bloggs}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages |name=author |suppressfields=author}}<
</pre>
 
==Option to get 'raw value'==
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50}}<
There should be an option to get '''raw value''' of a wikidata item using this module, similar to what we get from {{code|{{wikidata{{!}}property{{!}}raw{{!}}...}}}}.
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |Fred Bloggs}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages |name=author}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages; |name=author |Freda Bloggs}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=author; number_of_pages |name=author |suppressfields=author}}<
 
Absence of this option makes the template difficult to be used in infoboxes which require some wikidata property of a wikidata item which in turn is specified by some property of the given {{para|qid}}.
=== Only sourced ===
<pre>
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |onlysourced=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |onlysourced=yes}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=yes}}<
</pre>
 
This is necessary in order to comply with [[Wikipedia:Wikidata/2018 Infobox RfC | this RFC]] and [[Wikipedia:Wikidata#Appropriate_usage_in_articles|this list of RFCs]] which make it mandatory to use {{tl|Wdib}} with {{para|osd|true}} in infoboxes.
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |onlysourced=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |onlysourced=yes}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P166 |fetchwikidata=ALL |name=awards |onlysourced=yes}}<
 
An example requirement is {{para|mla}} of {{tl|Infobox Indian Constituency (wd)}}. [[User Talk:Riteze|<span style="color:green;">Riteze</span>]] 08:19, 4 March 2025 (UTC)
=== No icon ===
<pre>
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=yes}}<
</pre>
 
== open and close quotation mark ==
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=no}}<
# >{{#invoke:WikidataIB |getValue |qid=Q1396889 |P50 |fetchwikidata=ALL |name=author |noicon=yes}}<
 
Many of [[Quotation mark]]s have opening and closing, so both open and close quotation mark should be able to specified in [[Module:WikidataIB/titleformats|/titleformats]]. [[User:FlatLanguage|FlatLanguage]] ([[User talk:FlatLanguage|talk]]) 18:54, 26 March 2025 (UTC)
== Coordinates ==
:Please see [[MOS:CURLY]]. – [[User:Jonesey95|Jonesey95]] ([[User talk:Jonesey95|talk]]) 01:57, 27 March 2025 (UTC)
 
::/titleformats is for i18n, so projects other than enwiki should be considered. --[[User:FlatLanguage|FlatLanguage]] ([[User talk:FlatLanguage|talk]]) 01:59, 27 March 2025 (UTC)
Just to note that it would be nice to be able to set the coordinates to display both inline and in the title (passing "|display=inline,title" to {{tl|coord}}); this module just seems to allow inline coordinates. Thanks. [[User:Mike Peel|Mike Peel]] ([[User talk:Mike Peel|talk]]) 17:37, 18 December 2016 (UTC)