Difference between revisions of "Widget:ImageLoader"
(updated image loader) |
|||
Line 26: | Line 26: | ||
To use this widget on your site, just install [http://www.mediawiki.org/wiki/Extension:Widgets MediaWiki Widgets extension] and copy [{{fullurl:{{FULLPAGENAME}}|action=edit}} full source code] of this page to your wiki as '''{{FULLPAGENAME}}''' article. | To use this widget on your site, just install [http://www.mediawiki.org/wiki/Extension:Widgets MediaWiki Widgets extension] and copy [{{fullurl:{{FULLPAGENAME}}|action=edit}} full source code] of this page to your wiki as '''{{FULLPAGENAME}}''' article. | ||
</noinclude><includeonly><script type="text/javascript"> | </noinclude><includeonly><script type="text/javascript"> | ||
− | <!--{$url|validate:url}-->", "id" : null, "imgBuf" : null, "loading" : false }; | + | (function( ) |
+ | { | ||
+ | "use strict"; | ||
+ | var imageObj = { "src" : "<!--{$url|validate:url}-->", "id" : null, "imgBuf" : null, "loading" : false }; | ||
function setFilter( _img, _filter ) | function setFilter( _img, _filter ) |
Revision as of 11:31, 9 December 2014
This widget allows you to embed images from non-https sources on your wiki page.
Created by Xopr
Using this widget
To insert this widget, use the following code:
{{#widget:ImageLoader |url=https://upload.wikimedia.org/wikipedia/commons/b/b8/Trojan_Room_coffee_pot_xcoffee.png |width=300 |height=250 |interval=60 }}
This will give the following result: Note that url is mandatory, the test is optional (leave out interval to make the image static)
Copy to your site
To use this widget on your site, just install MediaWiki Widgets extension and copy full source code of this page to your wiki as Widget:ImageLoader article.