I have been breaking my head about this.
But when I use the {{filepath:someimage.png|nowiki}} in a page, it will generate the full URL, but with the colon in the "http://" part escaped to : . I am passing this URL to a Widget and really need the exact string to be used in CSS. For now I am simply using a replace-assign in the Widget to unescape the colon again.
But I noticed that on MediaWiki.org itself the colon doesn't seem to be escaped. I wonder why it doesn't happen there, but does for me.
Example: http://armeagle.nl/mediawiki/index.php/ColonTest (will not stay up forever, so the code is below too - though you'll have to upload or use your own image of course).
Version info: MediaWiki 1.16.0 PHP 5.2.6-1+lenny8 (apache2handler) MySQL 5.0.51a-24+lenny4-log
Any help is much appreciated,
ArmEagle
----------
<pre> {{filepath:Pbmap_icons.png|nowiki}} </pre> Will generate the following: <pre> <p>http://armeagle.nl/mediawiki/images/d/da/Pbmap_icons.png </p> </pre> I expect it not to escape the colon in the url. For some reason this does not seem to happen on http://www.mediawiki.org/. I am trying to figure out how I can prevent this from happening.
----
Actual usage of <nowiki>{{filepath:Pbmap_icons.png|nowiki}}</nowiki>:
{{filepath:Pbmap_icons.png|nowiki}}
ArmEagle wrote:
I have been breaking my head about this.
But when I use the {{filepath:someimage.png|nowiki}} in a page, it will generate the full URL, but with the colon in the "http://" part escaped to : . I am passing this URL to a Widget and really need the exact string to be used in CSS. For now I am simply using a replace-assign in the Widget to unescape the colon again.
But I noticed that on MediaWiki.org itself the colon doesn't seem to be escaped. I wonder why it doesn't happen there, but does for me.
Example: http://armeagle.nl/mediawiki/index.php/ColonTest (will not stay up forever, so the code is below too - though you'll have to upload or use your own image of course).
Version info: MediaWiki 1.16.0 PHP 5.2.6-1+lenny8 (apache2handler) MySQL 5.0.51a-24+lenny4-log
Any help is much appreciated,
ArmEagle
<pre> {{filepath:Pbmap_icons.png|nowiki}} </pre>
Will generate the following:
<pre> <p>http://armeagle.nl/mediawiki/images/d/da/Pbmap_icons.png </p> </pre>
I expect it not to escape the colon in the url. For some reason this does not seem to happen on http://www.mediawiki.org/. I am trying to figure out how I can prevent this from happening.
Actual usage of <nowiki>{{filepath:Pbmap_icons.png|nowiki}}</nowiki>:
{{filepath:Pbmap_icons.png|nowiki}}
Doesn't escape the colon here. That looks like an armored link.
And it isn't there, either:
<hr> <p>Actual usage of {{filepath:Pbmap_icons.png|nowiki}}: </p><p>http://armeagle.nl/mediawiki/images/d/da/Pbmap_icons.png </p>
mediawiki-l@lists.wikimedia.org