Question: Is possible to change default language

ddangel0

New Member
Aug 21, 2020
9
1
1
44
Hello, I wanted to know if what I need to do is possible and in what way it could be done.
I am about to put into production the quarantine of emails with tickets

The problem is that we need that by default when the user opens the link with the ticket for the first time, it appears in Spanish, so that the user does not have to go to select the language, that is, avoid that step.

Since I didn't find any settings to force it, try modifying the file:

/usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js

On the line :

return Proxmox.Utils.defaultText + '(English)';

by

return Proxmox.Utils.defaultText + '(Spanish)';

In this way when I open the https://server:8006/quarantine I see that Spanish is selected, but the change of language does not apply, everything is still in English

As I am not a programmer I don't know how to continue, if someone could do this and can tell me how, I really appreciate it.
I'm using:

proxmox-mailgateway: 6.2-1 (API: 6.2-5/05a7829e, running kernel: 4.9.0-3-amd64)
pmg-api: 6.2-5
pmg-gui: 2.2-2
pve-kernel-5.4: 6.2-4
pve-kernel-helper: 6.2-4
pve-kernel-5.4.44-2-pve: 5.4.44-2
clamav-daemon: 0.102.4+dfsg-0+deb10u1
libarchive-perl: 3.3.3-1
libjs-extjs: 6.0.1-10
libjs-framework7: 4.4.7-1
libpve-apiclient-perl: 3.0-3
libpve-common-perl: 6.1-3
libpve-http-server-perl: 3.0-6
libxdgmime-perl: 0.01-5
pmg-docs: 6.2-2
pmg-log-tracker: 2.1.6-1
postgresql-11: 11.7-0+deb10u1
proxmox-mini-journalreader: 1.1-1
proxmox-spamassassin: 3.4.4-2
proxmox-widget-toolkit: 2.2-8
pve-firmware: 3.1-1
pve-xtermjs: 4.3.0-1
 

Steffenprox

Member
Feb 22, 2020
53
11
8
32
Sorry i was in the wrong Forum. the setting was for Proxmox VE
 
Last edited:

Stoiko Ivanov

Proxmox Staff Member
Staff member
May 2, 2018
5,985
826
148
The problem is that we need that by default when the user opens the link with the ticket for the first time, it appears in Spanish, so that the user does not have to go to select the language, that is, avoid that step.
Currently this is not possible - however the setting is stored in the browser per user - so your users would (in most cases) only need to select the language once

Anyways since this is the 4th request for something like this in the past 4 weeks - would you mind creating an enhancement request at our bugzilla?
https://bugzilla.proxmox.com

Thanks!
 

ddangel0

New Member
Aug 21, 2020
9
1
1
44
Currently this is not possible - however the setting is stored in the browser per user - so your users would (in most cases) only need to select the language once

Anyways since this is the 4th request for something like this in the past 4 weeks - would you mind creating an enhancement request at our bugzilla?
https://bugzilla.proxmox.com

Thanks!


I found a way to do it for whoever needs to do it,

edit the file: /usr/share/javascript/pmg-gui/pmg-index.html.tt


Replace the line:
Code:
<script type='text/javascript'> function gettext(buf) { return buf; } </script>

by the line:
Code:
<script type='text/javascript' src='/pve2/locale/pmg-lang-es.js'></script>

# Being pmg-lang-es.js the language for Spanish, changing depends on the language you need

run:

#: systemctl restart pmgproxy.service
 
  • Like
Reactions: EDSON MARIO

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!