dokuwiki / translate.dokuwiki.org

Web based tool to create and update translation patches for DokuWiki and DokuWiki plugins.
MIT License
8 stars 2 forks source link

'Missing placeholder' message for ordered placeholders #51

Closed Klap-in closed 1 year ago

Klap-in commented 11 years ago

It is gold-plating, i know.

When you apply instead of the default placeholder order a ordered one by using the %1$s variant, you got the message "Missing placeholder". It would be nice the tool recognize this pattern too, so it don't give a not relevant message.

Example: http://translate.dokuwiki.org/translate/dokuwiki?lang=ko , string key: media_viewold supported string:

%s (%s에 있음)

desired string:

%2$s (%1$s에 있음)

http://php.net/manual/en/function.sprintf.php

Klap-in commented 1 year ago

Regexp should now recognize practically all placeholders of php's sprintf() method: e924561db8d3669c485329ed690fe0331904528f