Talk:Streptomyces:Publications
From OpenWetWare
Jump to navigationJump to search
Toggle and Biblio
I thought this might be a useful example of my publication display using toggle and biblio extensions.
Taken from OpenWetWare:Toggle
Multiple
- item1
- item2
- toggle item1
- toggle item2
- toggle both items
* {{toggle|item1||item1 item}}
* {{toggle|item2||item2 item}}
* <span class="_toggler-item1">toggle item1</span>
* <span class="_toggler-item2">toggle item2</span>
* <span class="_toggler-item">toggle both items</span>
Taken from Template:Toggle
{{{1}}}
<div class="_toggle {{{3|}}}">{{{1}}}</div>
<div class="_toggle {{{3|}}}" style="display:none;">{{{2}}}</div>
My understanding and usage of Toggle with the template
<span class="_toggler-item1">toggle item1</span> <span class="_toggler-item2">toggle item2</span> <span class="_toggler-item">toggle both items</span>
- The text
item1aftertoggler-is a reference name to the text/link/biblio/item you want to toggle. - The text between the brackets
>toggle item1<is the text that shows on the wiki page.
{{toggle|item1||item1 item}}
{{toggle|item2||item2 item}}
- The text
item1aftertoggle|is whatever text/link/biblio/item you want to toggle. - The text
item1after||should be the same reference from the class line,<span class="_toggler-item1">toggle item1</span> - The text
itemis another reference to enable all the objects containing the same reference to be toggled together. - The code
{{togglemeans that the display text and the text/link/biblio/item, are passed into the template for parsing.
- The | enables the data to be sent to particular parts of the template.
<div class="_toggle {{{3|}}}">{{{1}}}</div>
<div class="_toggle {{{3|}}}" style="display:none;">{{{2}}}</div>
- The numbers 1 and 2 in the brackets receive the text/link/biblio/item to be toggled.
- The number 3 in brackets receives the reference names, i.e.
|%#124;item1 item}} - By using the code
{{toggle|item1||item1 item}}the text/link/biblio/item to be toggled is automatically on show. - If you want the default setting to for the text/link/biblio/item to be hidden by default, use the following:
{{toggle||item1|item1 item}}
- Note the change in position of the vertical bar, which sends the data to different section of the template to be handled and therefore has a different output (hidden).
Example
<span class="_toggler-Kelemen">2000 - Present</span>
<span class="_toggler-KelemenPre2000">Pre 2000</span>
<span class="_toggler-List">Toggle Lists</span>
{{toggle|<biblio> #[[Streptomyces:PublicationsKelemenList]]</biblio>||Kelemen List}}
{{toggle||<biblio> #[[Streptomyces:PublicationsKelemenListPre2000]]</biblio>|KelemenPre2000 List}}
2000 - Present Pre 2000 Toggle Lists
Error fetching PMID 17766240
Error fetching PMID 17462019
Error fetching PMID 15629942
Error fetching PMID 15255907
Error fetching PMID 12535070
Error fetching PMID 11401688
Error fetching PMID 17462019
Error fetching PMID 15629942
Error fetching PMID 15255907
Error fetching PMID 12535070
Error fetching PMID 11401688
- Error fetching PMID 17766240
- Error fetching PMID 17462019
- Error fetching PMID 15629942
- Error fetching PMID 15255907
- Error fetching PMID 12535070
- Error fetching PMID 11401688
- Alternativly, you don't have to refer to the template, you can import the code and use it directly. For example:
<span class="_toggler-Kelemen">Toggle 2000 - Present</span> <span class="_toggler-KelemenPre2000">Toggle Pre 2000</span> <span class="_toggler-List">Toggle Lists</span> <br> <div class="_toggle Kelemen List"><biblio> #[[Streptomyces:PublicationsKelemenList]]</biblio></div> <div class="_toggle KelemenPre2000 List" style="display:none;"><biblio> #[[Streptomyces:PublicationsKelemenListPre2000]]</biblio></div>
Toggle 2000 - Present
Toggle Pre 2000
Toggle Lists
Error fetching PMID 17766240
Error fetching PMID 17462019
Error fetching PMID 15629942
Error fetching PMID 15255907
Error fetching PMID 12535070
Error fetching PMID 11401688
Error fetching PMID 17462019
Error fetching PMID 15629942
Error fetching PMID 15255907
Error fetching PMID 12535070
Error fetching PMID 11401688
- Error fetching PMID 17766240
- Error fetching PMID 17462019
- Error fetching PMID 15629942
- Error fetching PMID 15255907
- Error fetching PMID 12535070
- Error fetching PMID 11401688