Wiki Authoring
From CK12 - Flexbooks
The following wiki authoring guide is best viewed on the wiki. If you wish to create a printed version of this file, I recommend printing it through your browser rather than using the Render PDF option as you would on chapters.
Other Wiki Authoring pages include:
Contents |
Style
URLs
Wiki input: [http://www.greatachievements.org/ http://www.greatachievements.org/]
Wiki output: http://www.greatachievements.org/
Lists
Nested Lists
Nested Unnumbered List
| Wiki input | Wiki output | PDF output |
|---|---|---|
| Bullet list with sub-bullets:
*one **sub one **sub two **sub three *two *three | Bullet list with sub-bullets:
|
|
Nested Numbered List
Tables
Basic Table
Wiki text
{| id="table:example" title="short caption"
|+ a longer, more verbose caption
! header 1
! header 2
! header 3
|-
| row 1, cell 1
| row 1, cell 2
| row 1, cell 3
|-
| row 2, cell 1
| row 2, cell 2
| row 2, cell 3
|}
Wiki output
| header 1 | header 2 | header 3 |
|---|---|---|
| row 1, cell 1 | row 1, cell 2 | row 1, cell 3 |
| row 2, cell 1 | row 2, cell 2 | row 2, cell 3 |
PDF output
Referencing Tables
Tables "float," meaning they may not appear in the PDF exactly where you place them within the chapter. Also, all tables have a Table # (see the example table above), that is automatically added when the PDF is generated. In future versions of Flexr we will allow for the referencing of tables by a variable (e.g., table:example). In the meantime, when we reference tables, we will do so using a template. The first parameter of the template will be the "name=" parameter used in the table, the second parameter will be the text we use in the meantime.
Wiki text
See {{Ref table |table:example|the table }} for an example of a 2 by 3 table.
Wiki output
Current output:
See the table for an example of a 2 by 3 table.
Future output:
See Table 1.5 for an example of a 2 by 3 table.
PDF output
Images
Image Template
The following template is produced by clicking on the new Image toolbar button:
{{Image
|id=
|source=
|size=
|align=
|caption=
|author=
|photo-by=
|artist=
|courtesy-of=
|modified-by=
|title=
|license=
|url=
|date=
|other=
}}
- id (required)
- The way in which you will reference the Figure later.
- E.g.,
id=EarSci-0101-02
- source (required)
- The Wiki page for the image
- E.g.,
Image:EarSci-0101-02.jpg
- size (required)
- thumbnail OR postcard OR fullpage; fullpage is the width of the text (to the margins); postcard is
of fullpage; thumbnail is
of fullpage.
- E.g.,
size=postcard
- align (required)
- left OR center OR right; this is not working in the current version of Flexr; all values are currently equivalent to center.
- E.g.,
align=center
- caption (optional)
- The caption appears below the Figure.
- E.g.,
caption=Soil erosion has the potential of destroying farm land.
- author (optional)
- The individual or organization that you should attribute. This is open ended, although certain licenses specify that the author of the work must be attributed
- E.g.,
author=CK-12 Foundation - E.g.,
author=NOAA - E.g.,
author=NASA
- photo-by (optional)
- A field to acknowledge who the photographer of this image was taken by.
- artist (optional)
- This field is if you wish to acknowledge the original artist, painter, sculptor of an artistic work (other than a photo).
- courtesy-of (optional)
- The work may have been given to the person listed as the author (or license holder) of the work and you wish to acknowledge them here.
- modified-by (optional)
- This field is used if this is a modification of an original work and we wish to acknowledge the person or organization that made the modifications.
- title (optional)
- The short-caption, official, or unofficial title that will appear in the bibliography when referencing the image.
- E.g.,
title=The Mona Lisa
- license (required)
- The license such as CC-BY-SA 2.0 or GNU-FDL; or it may be a statement about expiration of copyright such as Public Domain, etc.
- E.g.,
license=CC-BY-SA 2.0
- url (required)
- The URL from where the image was retrieved from. If possible link to the placeholder page for the image and not directly to the image file itself. Two placeholder examples follow.
- E.g.,
url=http://en.wikipedia.org/wiki/File:Leonhard_Euler_2.jpg - E.g.,
url=http://commons.wikimedia.org/wiki/File:Leonardo_self.jpg
- date (optional)
- This is an optional date field to specify when you retrieved the file. We are flexible on how dates are formatted. This could be useful in case the original file is overwritten with a different file.
- E.g.,
3 July, 2007 - E.g.,
3/7/2007
- other (optional)
- Additional data fields that need to be captured and that you would like to display below the first citation (for example, additional citations). This may be especially useful when the Figure is a composite of multiple images. Currently we do not have a way a simple way of handling multiple citations for a single figure.
Inline Images
At this time, Inline images are used when you must have the image display exactly in place. Furthermore, inline images should not have a caption, they should not be licensed by a third party or have any licensing and/or authoring information that is necessary to display. In most cases you will want to use the Image template and not the Inline image template. Template definition:
{{Inline image
|source=Image:name.png
|size=thumbnail OR postcard OR fullpage OR image size in pixels
}}
An example of image size in pixels might be 100px, or 300px.
In Inline image mode, we make the following estimates for thumbnail, postcard, and fullpage values:
Example: Wiki text
{{Image
|source=Image:VA-02-03.jpg
|caption= The Helium Nucleus
|size=thumbnail
|align=center
|author= CK-12 Foundation
|title= The Helium Nucleus
|license= Public Domain
|url=http://authors.ck12.org/wiki/index.php/Image:VA-02-03.jpg
}}
Example: Wiki output
Example: PDF
Inline Math
Wiki text
Inline math tags are used to format mathematics, e.g., <math>\frac{1}{\sqrt{y}}=\frac{1}{\sqrt{mx+b}}</math>, that is to be displayed within the body of the text.
Wiki output
Inline math tags are used to format mathematics, e.g.,
, that is to be displayed within the body of the text.
PDF output
Block Math
Do not use tables to format a combination of mathematics and text. See the multiline math examples. When adding text, use the\text{} command, not the \textbf{} command.
Wiki text
Block math tags are used to display blocks of mathematics, for example: <blockmath>\frac{1}{\sqrt{y}}=\frac{1}{\sqrt{mx+b}}</blockmath> Compare this with the Inline mathematics, above.
Wiki output
Block math tags are used to display blocks of mathematics, for example:
Compare this with the Inline mathematics, above.
PDF output
Todo
The Todo wiki template does not appear in the Flexr or in the final PDF output. The purpose of the Todo template is to keep track of issues (formatting, technical, or otherwise). If you wish to add a Todo to a table, image, or mathematical expression, do so after or before the item in question.
Example - Wiki text
This sentence is red. {{Todo | There is no way to add color to text at this time. | 10}}
Example - Wiki output
This sentence is red.
| Todo 10 | There is no way to add color to text at this time. |
|---|
Correct vs. Incorrect uses
Correct <math>y !={{Todo | Use the not-equals operator | 5}} mx + b</math>
Incorrect
<math>y != mx + b</math> {{Todo | Use the not-equals operator | 5}}
Problem Sets
We are introducing two templates Problem and Solution. If you have a collection of problems (or solutions), you can surround them with the templates Start Problem Set and End Problem Set to create an ordered-list of problems (or solutions).
{{Problem
|question=
|difficulty=
|solution=
|noset=
|show-solution=
}}
- question
- This is typically the problem statement.
- difficulty
- Beginner OR Intermediate OR Advanced are recommended values, however, any parameter that is set will be displayed.
- solution
- A solution or example solution to the question. By default this is not displayed.
- noset
- If show-solution has any value (e.g. show-solution=true), then the problem will not be a list-item (i.e., it won't start with <li>). Note, if you are not using the Start Problem Set/End Problem Set templates then you must set the noset element so that it does not display as a list item.
- show-solution
- If show-solution has any value (e.g. show-solution=true), then the solution will be displayed below the question.
Example: Basic Problem Set
This template assumes that you are going to be listing a set of problems in order. For example, if we enter the following:
{{Start Problem Set}}
{{Problem | question=Define the word organism. |difficulty=Beginner | solution=A living thing}}
{{Problem | question=Give two examples of processes that help organisms achieve homeostasis. | difficulty=Intermediate | solution=Filtering the blood to achieve water balance with kidneys; burning energy to stay warm; secrete insulin to regulate sugar.}}
{{Problem | question=What are three characteristics of living things? | difficulty=Intermediate | solution=Grow, Reproduce, Maintain a stable internal environment, Composed of cells.}}
{{End Problem Set}}
It will produce the following output:
- Define the word organism.
- Give two examples of processes that help organisms achieve homeostasis.
- What are three characteristics of living things?
Example: Basic Solution Set
It is typical for a problem set to be followed by solution set. To make this process easy, we created the Solution template. All one needs to do is paste all of the problems from a given problem set into the area that you wish to be come the solution set and change the name of the template from Problem to Solution. For example:
{{Start Problem Set}}
{{Solution | question=Define the word organism. |difficulty=Beginner | solution=A living thing}}
{{Solution | question=Give two examples of processes that help organisms achieve homeostasis. | difficulty=Intermediate | solution=Filtering the blood to achieve water balance with kidneys; burning energy to stay warm; secrete insulin to regulate sugar.}}
{{Solution | question=What are three characteristics of living things? | difficulty=Intermediate | solution=Grow, Reproduce, Maintain a stable internal environment, Composed of cells.}}
{{End Problem Set}}
Which will output as follows:
- A living thing
- Filtering the blood to achieve water balance with kidneys; burning energy to stay warm; secrete insulin to regulate sugar.
- Grow, Reproduce, Maintain a stable internal environment, Composed of cells.
Media/YouTube Videos
Here is a link to two example pages:
The syntax is like this:
<media class="youtube" id="PmJV8CHIqFc" />
The id can be gathered from the youtube URL. For example, let's say I have a link to the youtube video from the Kahn academy site that looks like this: http://www.youtube.com/watch?v=RJlEH5Jz80w&feature=youtube_gdata
I would replace that with the following:<media class="youtube" id="RJlEH5Jz80w" />and it would appear as follows:
Figure Introduction to using the periodic table to determine electron configurations










