nguyenkim thuat | 5 Jun 2012 15:29
Picon

Problem with upload file url

Hi,
 When uploading a file using the mediawiki API, i use this Url of the Upload page:
             
                                                   $url= "http://localhost/mediawki/index.php/Special:Upload";
But is this variable configurable?
I mean to get the url in any wiki langagues. Because the french wiki have the different url for this page, for exemple:
                                                     $url= "http://localhost/mediawki/index.php/Spécial:Téléverser"   instead

Best regards.


_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api
Chad | 5 Jun 2012 15:31
Picon

Re: Problem with upload file url

On Tue, Jun 5, 2012 at 9:29 AM, nguyenkim thuat
<kimthuatnguyenensimagfr <at> gmail.com> wrote:
> Hi,
>  When uploading a file using the mediawiki API, i use this Url of the Upload
> page:
>
>
                                                   $url=
> "http://localhost/mediawki/index.php/Special:Upload";
> But is this variable configurable?
> I mean to get the url in any wiki langagues. Because the french wiki have
> the different url for this page, for exemple:
>
                                                 
   $url=
> "http://localhost/mediawki/index.php/Spécial:Téléverser"   instead
>

[[Special:Upload]] will work on any wiki, since the English names (known
internally as the "canonical" page) will work regardless of the wiki's
language.

For example, if you go to http://fr.wikipedia.org/wiki/Special:Upload, you'll
see that it redirects automatically.

-Chad
_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api
nguyenkim thuat | 5 Jun 2012 15:46
Picon
Picon

Re: Problem with upload file url

On Tue, Jun 5, 2012 at 3:31 PM, Chad <innocentkiller <at> gmail.com> wrote:
On Tue, Jun 5, 2012 at 9:29 AM, nguyenkim thuat
<kimthuatnguyenensimagfr <at> gmail.com> wrote:
> Hi,
>  When uploading a file using the mediawiki API, i use this Url of the Upload
> page:
>
>                                                    $url=
> "http://localhost/mediawki/index.php/Special:Upload";
> But is this variable configurable?
> I mean to get the url in any wiki langagues. Because the french wiki have
> the different url for this page, for exemple:
>                                                      $url=
> "http://localhost/mediawki/index.php/Spécial:Téléverser"   instead
>

[[Special:Upload]] will work on any wiki, since the English names (known
internally as the "canonical" page) will work regardless of the wiki's
language.

For example, if you go to http://fr.wikipedia.org/wiki/Special:Upload, you'll
see that it redirects automatically.
That's true, thank you a lot. At first, i think that it will need to use the API to get this url for each language.
But now, there is no need to do it anymore.

Best regards.
-Chad
_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api

_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api

Gmane