Help:Images

From QMRAwiki
Jump to: navigation, search

Uploading

An easy way to upload an image is to create a link to your image, even if you haven't uploaded it yet. When you save your page, the name of the image will be red. Clicking on the red link will take you directly to a page that lets you upload your image. There is also an 'Upload file' link in the toolbox on the left. You can simply click Browse and locate the file of interest. If you want, write a brief summary about the image. Once you've located the file, click the Upload File button.

Using Images

Using images in QMRAwiki is done by doing the following: Let's say you want to link to an file (that happens to be an image). To do this, simply type [[File:Icon-hazard.png]] and the image will appear.

Icon-hazard.png

Clicking on the image will take you to that image's page in QMRAwiki.

Let's say though, that you wanted to make the picture smaller and move it to the right of the page. You can do this by adding some wiki code after the file name. For example, |thumb| will decrease the image to 120 pixels wide (a thumbnail). We can follow it with '30px' to make it 30 pixels wide. Writing [[File:Icon-hazard.JPG|thumb|right|30px]] will make the picture go to the right of the page, like this:
Icon-hazard.png

Now, our image is on the right, and we can write on the left.

Image inclusion syntax

To generalize the above: there is a syntax for adding images in Mediawiki wikis. To add an image, use:

[[file:ImageFileName|{type}|{location}|{size}|{caption}]]

{type}, {location}, {size}, and {caption} are all optional. Anything that is not recognizable as {type} {location} or {size} is treated as a caption.

  • type: allowed values are 'thumb', 'thumbnail' or 'frame'. If this is left blank, there is no box around the image, and it doesn't display a caption
  • location: allowed values are 'right', 'left', 'center' or 'none'. Text will wrap around 'left' or 'right' but not around 'center'. Use {{Clr}} to prevent text below from wrapping.
  • size:{width}px width in pixels. Ignored if type is 'frame'.

Examples

In the examples below, the image is placed at the beginning of a block of nonsense text, so you can see how wrapping around the image works.

Simple Image

[[File:Icon-hazard.png]]

Icon-hazard.pngLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum

Simple Image Resized

[[File:Icon-hazard.png|150px]]

Icon-hazard.pngLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum

Framed Images with caption

Default alignment: [[File:Icon-hazard.png|frame|Sample image figure legend]]

Sample image figure legend
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum

Centered: [[File:Icon-hazard.png|frame|50px|center| Sample image figure legend]]

Sample image figure legend
Note that size is ignored when frame is set. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum

See also

More about Images at meta and at Wikipedia. Embedded images on QMRAWiki must be uploaded, and then linked. To upload, go to Upload file from the toolbox. The most recently uploaded images and files are listed in Special:Newimages.