User:RexxS/Cite multiple pages

One of the problems I often come across is how to make several in-line citations which refer to different pages of the same book. The method illustrated below is one I've found which works. It involves three elements:
 * 1) an inline cite within the main article text, using harvnb inside the tags
 * 2) a or reflist within a "References" or similar section;
 * 3) a book cited within a "Bibliography" or similar section, using cite book, with the |ref parameter set to the autogenerated anchor that harvnb creates.

It is much easier to see an example than to describe how each step works. So have a look at this:

==Text of the article==

The effects of oxygen toxicity are commonly classified by the organs affected, producing three principal types:

The seizure ends with a period of unconsciousness (the postictal state).

==References==

==Bibliography==

*

The spacing within the parameters in harvnb are crucial: extra spaces generate underscores ("_") in the anchor link like "CITEREFBrubakk_Neuman_2003", so it no longer matches the |ref parameter that you put inside the cite book. You can check the generated link by hovering over the link in the "References" section and looking at the status bar to see what the CITEREFxxxxxx actually is.

This is what the wiki-code above produces (any comments welcome!):

Text of the article
The effects of oxygen toxicity are commonly classified by the organs affected, producing three principal types:

The seizure ends with a period of unconsciousness (the postictal state).

Addendum: defined references
Since I wrote the above, an expansion to allow references to be defined within Reflist has been implemented. The effect is to remove the definition of the reference from within the main text, making the article text much easier to edit. This isn't compulsory, but I feel that a little extra effort at the early stage makes further editing much easier.

Here's another example, illustrating "defined references" as well as mixing the Harvnb style with normal referencing. It also shows you can use the "|loc" parameter in Harvnb to refer to source locations other than simple pages. Note that it doesn't matter what order the defined references in Reflist are; so you can order them as you choose for ease of finding them again.


 * ==Text of the article==
 * However, exposure time before onset is unpredictable, as tests have shown a wide variation, both amongst individuals, and in the same individual from day to day.


 * Seizures during the therapy are managed by removing the mask from the patient, thereby dropping the partial pressure of oxygen inspired below 0.6 bar.


 * ==References==


 * ==Bibliography==

Text of the article
However, exposure time before onset is unpredictable, as tests have shown a wide variation, both amongst individuals, and in the same individual from day to day.

Seizures during the therapy are managed by removing the mask from the patient, thereby dropping the partial pressure of oxygen inspired below 0.6 bar.