Difference between revisions of "Adding Images to your Article"

From The DarkMod Wiki
Jump to navigationJump to search
m
m (update)
 
(3 intermediate revisions by the same user not shown)
Line 2: Line 2:
You can upload images directly to DarkWiki by using this page: [[Special:Upload]]. Once uploaded, include the image in a page using a link in the form <nowiki>[[Image:File.jpg]]</nowiki>
You can upload images directly to DarkWiki by using this page: [[Special:Upload]]. Once uploaded, include the image in a page using a link in the form <nowiki>[[Image:File.jpg]]</nowiki>


== Alternative: External Hosting ==
{{infobox|bg=#ff9070|text='''Note''': External hosting should not be used with the wiki, as external hosts tend to disappear, either temporarily or permanently, leaving the wiki articles without images. And since an image is worth 1000 words...}}
You will have to use some external hosting service like [http://imageshack.us ImageShack]. Once you know the URL of your linked image, copy and paste it into your text like this:


<nowiki>http://modetwo.net/darkmod/style_images/darkimg/darkmod-logo.jpg</nowiki>


The Wiki will recognize this as a link to an image and will automatically insert this image into your article at full size:
== Example image ==


http://modetwo.net/darkmod/style_images/darkimg/darkmod-logo.jpg
[[Image:Tdm wiki logo.png|This is the text displayed]]


== Adding ImageShack-Images to Wiki-Articles ==
Once you upload your image to ImageShack, a page containing a bunch of links appears. Copy the one named as "'''direct link to image'''" and paste it here like this:


<nowiki>http://img153.imageshack.us/img153/9927/shot00006xs8.jpg</nowiki>
== Floating images ==


This will insert the image at full size into your article.
Some example: [[Image:Tdm wiki logo.png|Floating right|right]]
[[Image:Tdm wiki logo.png|Floating left|left]]
{{clear}}


== Adding ImageShack-Images with Thumbnails ==
See [[Handling_Line_Breaks#Floating elements|here]] for how to achieve that effect.
Inserting large 1024x768 screenshots can make the reading of your article hard (and increases bandwidth consumption), so it's cleaner to create a clickable thumbnail that links to the full size image.


As above, copy and paste the link named "'''direct link to image'''" into your text, this time in single brackets:
== Images with a text below ==


<nowiki>[http://img153.imageshack.us/img153/9927/shot00006xs8.jpg]</nowiki>
Add '''thumb''' to the image link and use <nowiki>{{clear}}</nowiki> afterwards:


This will create a link to the full sized image. Now insert the link description, which in our case is the thumbnail of this image.
<nowiki>[[Image:Tdm wiki logo.png|The Dark Mod logo|thumb]] {{clear}}</nowiki>
For Firefox-Users just right-click on the actual preview thumbnail that ImageShack is showing you after upload and choose "Copy Image Location" and paste it right before the closing bracket like this (and after the space):


<nowiki>[http://img153.imageshack.us/img153/9927/shot00006xs8.jpg http://img153.imageshack.us/img153/9927/shot00006xs8.th.jpg]</nowiki>
[[Image:Tdm wiki logo.png|The Dark Mod logo|thumb]] {{clear}}


Note the space between the two links that is necessary to tell DarkWiki that these are two seperate strings. Now the thumbnail will be used as description for this external link.
== Resizing images ==


Note: If you look closely you'll notice that the only difference between these two links is the thumbnail using '''.th.jpg''' instead of '''.jpg'''. As long as ImageShack doesn't change this format, you can also duplicate the link to the full image and insert the '''.th''' manually, thus saving the "Copy Image Location" part.
You can ask the wiki to resize an image to any width by add <nowiki>|XXXpx</nowiki> in the image link, where XXX is the number of pixels, f.i. 220. Make sure that it is not too big or small.


The result will look like this:
[[Image:Trans_0013.jpg|320px|This image is scaled to 320 pixel]] [[Image:Trans_0013.jpg|240px|This image is scaled to 240 pixel]] [[Image:Trans_0013.jpg|160px|This image is scaled to 160 pixel]]


[http://img153.imageshack.us/img153/9927/shot00006xs8.jpg http://img153.imageshack.us/img153/9927/shot00006xs8.th.jpg]


[[Category:Tutorial]]
{{tutorial-wiki|sort=Images}}
[[Category:Wiki]]

Latest revision as of 13:09, 23 March 2012

Upload the Image to DarkWiki

You can upload images directly to DarkWiki by using this page: Special:Upload. Once uploaded, include the image in a page using a link in the form [[Image:File.jpg]]

Note: External hosting should not be used with the wiki, as external hosts tend to disappear, either temporarily or permanently, leaving the wiki articles without images. And since an image is worth 1000 words...


Example image

This is the text displayed


Floating images

Some example:

Floating right
Floating left

See here for how to achieve that effect.

Images with a text below

Add thumb to the image link and use {{clear}} afterwards:

[[Image:Tdm wiki logo.png|The Dark Mod logo|thumb]] {{clear}}

The Dark Mod logo

Resizing images

You can ask the wiki to resize an image to any width by add |XXXpx in the image link, where XXX is the number of pixels, f.i. 220. Make sure that it is not too big or small.

This image is scaled to 320 pixel This image is scaled to 240 pixel This image is scaled to 160 pixel