[pve-devel] [proxmox-i18n] Gettext complex examples

Daniel Koć daniel at xn--ko-wla.pl
Sun Nov 26 09:12:00 CET 2023


Hi,

I'd like to gettextize (make translatable) more strings than currently, 
to eventually have full translation of UI. I have a problem how to add 
gettext for such strings as in WidgetToolkitUtils.js:

     getNoSubKeyHtml: function(url) {
     return Ext.String.format('You do not have a valid subscription for 
this server. Please visit <a target="_blank" 
href="{0}">www.proxmox.com</a> to get a list of available options.', url 
|| 'https://www.proxmox.com');
     },

Is it just a simple trick like:

return Ext.String.format(*gettext(*'You do not have a valid subscription 
for this server. Please visit <a target="_blank" 
href="{0}">www.proxmox.com</a> to get a list of available options.'*)*, 
url || 'https://www.proxmox.com');

or something more complex is needed?

-- 
"It was the wrong plan in the wrong hands" [M. Gore]



More information about the pve-devel mailing list