සැකිල්ල:URL/testcases
This is the template test cases page for the sandbox of සැකිල්ල:URL. Purge this page to update the examples. If there are many examples of a complicated template, later ones may break due to limits in MediaWiki, see the HTML comment "NewPP limit report" in the rendered page. You can also use Special:ExpandTemplates to examine the results of template uses. You can test how this page looks in the different skins with these links: |
{{URL| http:// }}
Template | Sandbox |
---|---|
[http:// ]<span class="url">[http:// ]</span> |
[http:// ]<span class="url">[http:// ]</span> |
{{URL| example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://example.com example.com]</span> |
example<span class="url">[http://example.com example<wbr/>.com]</span> |
{{URL| EXAMPLE.COM }}
Template | Sandbox |
---|---|
EXAMPLE.COM<span class="url">[http://EXAMPLE.COM EXAMPLE.COM]</span> |
example<span class="url">[http://EXAMPLE.COM example<wbr/>.com]</span> |
{{URL| www.example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://www.example.com example.com]</span> |
www<span class="url">[http://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| WWW.EXAMPLE.COM }}
Template | Sandbox |
---|---|
EXAMPLE.COM<span class="url">[http://WWW.EXAMPLE.COM EXAMPLE.COM]</span> |
www<span class="url">[http://WWW.EXAMPLE.COM www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://www.example.com example.com]</span> |
www<span class="url">[http://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| https://www.example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[https://www.example.com example.com]</span> |
www<span class="url">[https://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com/ }}
Template | Sandbox |
---|---|
example.com/<span class="url">[http://www.example.com/ example.com/]</span> |
www<span class="url">[http://www.example.com/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| https://www.EXAMPLE.cOm }}
Template | Sandbox |
---|---|
EXAMPLE.cOm<span class="url">[https://www.EXAMPLE.cOm EXAMPLE.cOm]</span> |
www<span class="url">[https://www.EXAMPLE.cOm www<wbr/>.example<wbr/>.com]</span> |
{{URL| HTTPS://www.EXAMPLE.cOm/ }}
Template | Sandbox |
---|---|
EXAMPLE.cOm/<span class="url">[HTTPS://www.EXAMPLE.cOm/ EXAMPLE.cOm/]</span> |
www<span class="url">[HTTPS://www.EXAMPLE.cOm/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| https://www.example.com/ }}
Template | Sandbox |
---|---|
example.com/<span class="url">[https://www.example.com/ example.com/]</span> |
www<span class="url">[https://www.example.com/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://example.com example.com]</span> |
example<span class="url">[http://example.com example<wbr/>.com]</span> |
{{URL| https://example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[https://example.com example.com]</span> |
example<span class="url">[https://example.com example<wbr/>.com]</span> |
{{URL| ftp://example.com }}
Template | Sandbox |
---|---|
ftp://example.com<span class="url">[http://ftp://example.com ftp://example.com]</span> |
example<span class="url">[ftp://example.com example<wbr/>.com]</span> |
{{URL| ftp://www.example.com/ }}
Template | Sandbox |
---|---|
ftp://www.example.com/<span class="url">[http://ftp://www.example.com/ ftp://www.example.com/]</span> |
www<span class="url">[ftp://www.example.com/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[http://www.example.com/foo/bar example.com/foo/bar]</span> |
www<span class="url">[http://www.example.com/foo/bar www<wbr/>.example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| http://www.example.com/foo/bar/ }}
Template | Sandbox |
---|---|
example.com/foo/bar/<span class="url">[http://www.example.com/foo/bar/ example.com/foo/bar/]</span> |
www<span class="url">[http://www.example.com/foo/bar/ www<wbr/>.example<wbr/>.com<wbr/>/foo<wbr/>/bar<wbr/>/]</span> |
{{URL| http://www.example.com/foO/BaR }}
Template | Sandbox |
---|---|
example.com/foO/BaR<span class="url">[http://www.example.com/foO/BaR example.com/foO/BaR]</span> |
www<span class="url">[http://www.example.com/foO/BaR www<wbr/>.example<wbr/>.com<wbr/>/foO<wbr/>/BaR]</span> |
{{URL| https://www.example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[https://www.example.com/foo/bar example.com/foo/bar]</span> |
www<span class="url">[https://www.example.com/foo/bar www<wbr/>.example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| http://example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[http://example.com/foo/bar example.com/foo/bar]</span> |
example<span class="url">[http://example.com/foo/bar example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| https://example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[https://example.com/foo/bar example.com/foo/bar]</span> |
example<span class="url">[https://example.com/foo/bar example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[http://example.com/foo/bar example.com/foo/bar]</span> |
example<span class="url">[http://example.com/foo/bar example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| www.example.com/foo/bar }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[http://www.example.com/foo/bar example.com/foo/bar]</span> |
www<span class="url">[http://www.example.com/foo/bar www<wbr/>.example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL| http://example.com/foo/bar | }}
Template | Sandbox |
---|---|
example.com/foo/bar<span class="url">[http://example.com/foo/bar example.com/foo/bar]</span> |
example<span class="url">[http://example.com/foo/bar example<wbr/>.com<wbr/>/foo<wbr/>/bar]</span> |
{{URL|1=http://www.example.com?foo=BaR}}
Template | Sandbox |
---|---|
example.com?foo=BaR<span class="url">[http://www.example.com?foo=BaR example.com?foo=BaR]</span> |
www<span class="url">[http://www.example.com?foo=BaR www<wbr/>.example<wbr/>.com?foo=BaR]</span> |
{{URL| http://www.example.com#fooBaR }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://www.example.com#fooBaR example.com]</span> |
www<span class="url">[http://www.example.com#fooBaR www<wbr/>.example<wbr/>.com<wbr/>#fooBaR]</span> |
{{URL| http://www.example.com }}
Template | Sandbox |
---|---|
example.com<span class="url">[http://www.example.com example.com]</span> |
www<span class="url">[http://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com:8080 }}
Template | Sandbox |
---|---|
example.com:8080<span class="url">[http://www.example.com:8080 example.com:8080]</span> |
www<span class="url">[http://www.example.com:8080 www<wbr/>.example<wbr/>.com:8080]</span> |
{{URL| http://www.example.com:8080/foo/bar }}
Template | Sandbox |
---|---|
example.com:8080/foo/bar<span class="url">[http://www.example.com:8080/foo/bar example.com:8080/foo/bar]</span> |
www<span class="url">[http://www.example.com:8080/foo/bar www<wbr/>.example<wbr/>.com:8080<wbr/>/foo<wbr/>/bar]</span> |
{{URL| www.example.com:8080 }}
Template | Sandbox |
---|---|
example.com:8080<span class="url">[http://www.example.com:8080 example.com:8080]</span> |
www<span class="url">[http://www.example.com:8080 www<wbr/>.example<wbr/>.com:8080]</span> |
{{URL| www.example.com:8080/foo/bar }}
Template | Sandbox |
---|---|
example.com:8080/foo/bar<span class="url">[http://www.example.com:8080/foo/bar example.com:8080/foo/bar]</span> |
www<span class="url">[http://www.example.com:8080/foo/bar www<wbr/>.example<wbr/>.com:8080<wbr/>/foo<wbr/>/bar]</span> |
{{URL| http://www.example.com/foo bar }}
Template | Sandbox |
---|---|
bar example.com/foo bar<span class="url">[http://www.example.com/foo bar example.com/foo bar]</span> |
www<span class="url">[http://www.example.com/foo%20bar www<wbr/>.example<wbr/>.com<wbr/>/foo%20bar]</span> |
{{URL| www.example.com/foo bar }}
Template | Sandbox |
---|---|
bar example.com/foo bar<span class="url">[http://www.example.com/foo bar example.com/foo bar]</span> |
www<span class="url">[http://www.example.com/foo%20bar www<wbr/>.example<wbr/>.com<wbr/>/foo%20bar]</span> |
{{URL| http://example.com/foo/bar | link }}
{{URL| https://example.com/foo/bar | link }}
{{URL| example.com/foo/bar | link }}
{{URL| www.example.com/foo/bar | link }}
{{URL| www.example.com/foo/bar | 捦挺挎 }}
{{URL| www.example.com/foo/捦挺挎/bar | link }}
{{URL| عمان.icom.museum }}
Template | Sandbox |
---|---|
عمان.icom.museum<span class="url">[http://عمان.icom.museum عمان.icom.museum]</span> |
عمان<span class="url">[http://عمان.icom.museum عمان<wbr/>.icom<wbr/>.museum]</span> |
{{URL| http://عمان.icom.museum }}
Template | Sandbox |
---|---|
عمان.icom.museum<span class="url">[http://عمان.icom.museum عمان.icom.museum]</span> |
عمان<span class="url">[http://عمان.icom.museum عمان<wbr/>.icom<wbr/>.museum]</span> |
{{URL| 1964thetribute.com }}
Template | Sandbox |
---|---|
1964thetribute.com<span class="url">[http://1964thetribute.com 1964thetribute.com]</span> |
1964thetribute<span class="url">[http://1964thetribute.com 1964thetribute<wbr/>.com]</span> |
{{URL| 1964thetribute.com | 1964thetribute.com }}
Template | Sandbox |
---|---|
1964thetribute.com <span class="url">[http://1964thetribute.com 1964thetribute.com ]</span> |
1964thetribute.com<span class="url">[http://1964thetribute.com 1964thetribute.com]</span> |
{{URL|http://www.example.com/foo/bar?a=b&c=d}}
Template | Sandbox |
---|---|
{{URL|example.com}} |
www |
{{URL| http:www.example.com }}
Template | Sandbox |
---|---|
http:www.example.com<span class="url">[http://http:www.example.com http:www.example.com]</span> |
www<span class="url">[http://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| http:/www.example.com }}
Template | Sandbox |
---|---|
http:/www.example.com<span class="url">[http://http:/www.example.com http:/www.example.com]</span> |
www<span class="url">[http://www.example.com www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com/# }}
Template | Sandbox |
---|---|
example.com/<span class="url">[http://www.example.com/# example.com/]</span> |
www<span class="url">[http://www.example.com/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example.com/? }}
Template | Sandbox |
---|---|
example.com/?<span class="url">[http://www.example.com/? example.com/?]</span> |
www<span class="url">[http://www.example.com/ www<wbr/>.example<wbr/>.com]</span> |
{{URL| http://www.example1.com<br>http://www.example2.com }}
Template | Sandbox |
---|---|
http://www.example2.com http://www.example1.com http://www.example2.com <span class="url">[http://http://www.example1.com<br>http://www.example2.com http://www.example1.com<br>http://www.example2.com]</span> |
http://www.example2.com http://www.example1.com http://www.example2.com <span class="url">[http://www.example1.com<br>http://www.example2.com http://www.example1.com<br>http://www.example2.com]</span> |
{{URL| http://www.example1.com and http://www.example2.com/ }}
Template | Sandbox |
---|---|
and http://www.example2.com/ example1.com and http://www.example2.com/<span class="url">[http://www.example1.com and http://www.example2.com/ example1.com and http://www.example2.com/]</span> |
http://www.example1.com%20and%20http://www.example2.com/<span class="url">[http://www.example1.com%20and%20http://www.example2.com/ http://www.example1.com%20and%20http://www.example2.com/]</span> |
{{URL|1=http://www.example.com/foo/bar?a=b&c=d}}
Template | Sandbox |
---|---|
example.com/foo/bar?a=b&c=d<span class="url">[http://www.example.com/foo/bar?a=b&c=d example.com/foo/bar?a=b&c=d]</span> |
www<span class="url">[http://www.example.com/foo/bar?a=b&c=d www<wbr/>.example<wbr/>.com<wbr/>/foo<wbr/>/bar?a=b&c=d]</span> |
{{URL|2=example.com}}
Template | Sandbox |
---|---|
{{URL|example.com}} <code>{{[[සැකිල්ල:URL|URL]]|example.com}}</code> |
example.comexample.com |
{{URL|2=http://example.com/foo}}
Template | Sandbox |
---|---|
{{URL|example.com}} <code>{{[[සැකිල්ල:URL|URL]]|example.com}}</code> |
http://example.com/foohttp://example.com/foo |
{{URL| http://www.example.com | example }}
{{URL| 1=http://www.sho.com/site/dexter/home.sho| 2=''Dexter''{{'}}s official website}}
Template | Sandbox |
---|---|
Dexter's official website<span class="url">[http://www.sho.com/site/dexter/home.sho ''Dexter''<span style="padding-left:0.1em;">'</span>s official website]</span> |
Dexter's official website<span class="url">[http://www.sho.com/site/dexter/home.sho ''Dexter''<span style="padding-left:0.1em;">'</span>s official website]</span> |
Warning examples
සංස්කරණයIf the URL may contain equal signs, the parameters should be numbered explicitly to have the template work as expected (otherwise, parameter value overrides may occur) ; this is more problematic when an explicit display text is provided in parameter 2.
There's absolutely never any problem when the parameter 2 is explicitly passed, but in this case, using this template is not even needed, and standard Wiki link syntax will be fully equivalent and in fact simpler to edit and faster to compute on the server.
Code | Result | Sandbox Result |
---|---|---|
{{URL| http://www.ex=ample.com}} | {{URL|example.com}}
|
www |
{{URL| http://www.ex=ample.com | example }} | example | example |
{{URL| 1=http://www.ex=ample.com | 2=example }} | example | example |
Word wrapping test
සංස්කරණයCode | Result | Sandbox Result | Manual invokation |
---|---|---|---|
{{URL| 1=http://www.example.com |2=Supercalifragilistic__expialidocious}} | Supercalifragilistic__expialidocious | Supercalifragilistic__expialidocious | Supercalifragilistic__expialidocious |
{{URL| 1=http://www.example.com |2=Supercalifragilistic//expialidocious}} | Supercalifragilistic//expialidocious | Supercalifragilistic//expialidocious | Supercalifragilistic//expialidocious |
{{URL| 1=http://www.example.com |2=Supercalifragilistic..expialidocious}} | Supercalifragilistic..expialidocious | Supercalifragilistic..expialidocious | Supercalifragilistic..expialidocious |
{{URL| 1=http://www.example.com |2=Supercalifragilistic##expialidocious}} | Supercalifragilistic##expialidocious | Supercalifragilistic##expialidocious | Supercalifragilistic##expialidocious |