Welcome to the nuBuilder forums!

Please register and login to view forums and other content only available to registered users.

Translation in nuBuilder 2.7.4.3

Locked
massiws
Posts: 503
Joined: Thu May 24, 2012 2:08 am
Location: Milan, Italy
Contact:

Translation in nuBuilder 2.7.4.3

Unread post by massiws »

Hi all, I upgrade to nuBuilder 2.7.4.3 and works fine with translations! :D

I have only one consideration (a proposal) to do.
Now, the language choice is made according to a value in zzsys_setup table.
In this way, all users have the messages set to that language; but if users have different languages​​?
Why don't set language in zzsys_user table instead of zzsys_setup? In this way nuBuilder could respond with messages in the user language (obviously, zzsys_translation should contain all languages).
To reduce database queries and improve performance, all the translated strings could be load and store on application start-up.
It would probably be a very special case, but in small countries (like Europe) might even happen!

Don't misunderstand me: I really appreciate your work!!

Only, I changed a few lines of code to allow the translation of the strings below:
- "You do not have access"
- "No Such Report"
- "Report has Expired"
- "You have been logged out"

With the help of my IDE I simple find and replace the original:

Code: Select all

print 'you have been logged out ..';

with:
print nuTranslate('you have been logged out ..');
and so on for all text strings.

Also, to display the correct translation in subform, I made this change in form.php, line 2351:

Code: Select all

 from:
$s  .= "$TAB         <span style='vertical-align:top;font-size:10pt;font-family:tahoma;font-weight:bold;'>&nbsp;Delete&nbsp;</span>$CRLF";

to:
$s  .= "$TAB         <span style='vertical-align:top;font-size:10pt;font-family:tahoma;font-weight:bold;'>" .nuTranslate('Delete'). "</span>$CRLF";
Hope this helps.
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Translation in nuBuilder 2.7.4.3

Unread post by admin »

massiws,

I'll add these phrases next version.

On the topic of personalised languages,

It would be used in less than 1% of applications, especially considering that all the users of an application would need to use the same language for general data entry anyway.

We want to keep nuBuilder simple and even adding 1 exra field that every admin person will need to address every time they add a user (even if they don't fill it out) will only be done if its absolutely nessecary.

Steven
massiws
Posts: 503
Joined: Thu May 24, 2012 2:08 am
Location: Milan, Italy
Contact:

Re: Translation in nuBuilder 2.7.4.3

Unread post by massiws »

We want to keep nuBuilder simple and even adding 1 exra field that every admin person will need to address every time they add a user (even if they don't fill it out) will only be done if its absolutely nessecary.
That's a good reason! :)

Regards.
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Translation in nuBuilder 2.7.4.3

Unread post by admin »

massiws,

If you send me your translation, I'll include it in new releases.

Steven
massiws
Posts: 503
Joined: Thu May 24, 2012 2:08 am
Location: Milan, Italy
Contact:

Re: Translation in nuBuilder 2.7.4.3

Unread post by massiws »

Steven,
here the Italian translation.

Thank you.
Attachments
language.it.zip
(14.95 KiB) Downloaded 376 times
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Translation in nuBuilder 2.7.4.3

Unread post by admin »

massiws,

I can't open it, can you send it as sql (even just as a post)

Steven
massiws
Posts: 503
Joined: Thu May 24, 2012 2:08 am
Location: Milan, Italy
Contact:

Re: Translation in nuBuilder 2.7.4.3

Unread post by massiws »

Steven,
I can't attach files with .sql or .xsl extension: I tryed to compress it with gzip.
language-it.sql.tar.gz
csv format
(2.24 KiB) Downloaded 365 times
Here is the dump of zzsys_translate table:

Code: Select all

-- phpMyAdmin SQL Dump

CREATE TABLE IF NOT EXISTS `zzsys_translate` (
  `zzsys_translate_id` varchar(15) NOT NULL,
  `trl_language` varchar(20) NOT NULL,
  `trl_english` varchar(300) NOT NULL,
  `trl_translation` varchar(300) NOT NULL,
  PRIMARY KEY (`zzsys_translate_id`),
  KEY `trl_language` (`trl_language`),
  KEY `trl_english` (`trl_english`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

--
-- Dump dei dati per la tabella `zzsys_translate`
--

INSERT INTO `zzsys_translate` (`zzsys_translate_id`, `trl_language`, `trl_english`, `trl_translation`) VALUES
('150242be8c00a1', 'it', 'Close', 'Chiudi'),
('150242be8c00a5', 'it', 'Are You Sure?', 'Confermi?'),
('150242be8c00a8', 'it', 'Print', 'Stampa'),
('150242be8c00ab', 'it', 'Save', 'Salva'),
('150242be8c011d', 'it', 'Delete', 'Elimina'),
('150242be8c00b0', 'it', 'Add Record', 'Nuovo'),
('150242be8c00b3', 'it', 'Clone', 'Duplica'),
('150242be8c00bc', 'it', 'Logout', 'Esci'),
('150242be8c00bf', 'it', 'Page', 'Pagina'),
('150242be8c00c1', 'it', 'Search', 'Cerca'),
('150242be8c00c4', 'it', 'You are here', 'Ti trovi qui'),
('150242be8c00c7', 'it', 'Cancel', 'Cancella'),
('150242be8c00c9', 'it', 'Error!', 'Errore!'),
('150242be8c00cc', 'it', 'Send Email', 'Invia Email'),
('150242be8c00cf', 'it', 'Email Successfully Sent', 'Email inviata correttamente'),
('150242be8c00d2', 'it', 'The Email Is Sending', 'Invio Email in corso...'),
('150242be8c00d5', 'it', 'Please Wait...', 'Attendere prego...'),
('150242be8c00d8', 'it', 'Send Read Receipt', 'Inviare confema di lettura'),
('150242be8c00da', 'it', 'Report ID', 'Report ID'),
('150242be8c00dd', 'it', 'Filetype', 'Filetype'),
('150242be8c00e0', 'it', 'Attached Report', 'Report allegato'),
('150242be8c00e3', 'it', 'Message', 'Messaggio'),
('150242be8c00e6', 'it', 'Subject', 'Soggetto'),
('150242be8c00e8', 'it', 'ReplyTo', 'Rispondi'),
('150242be8c00eb', 'it', 'From', 'Da'),
('150242be8c0112', 'it', 'No', 'No'),
('150242be8c00f3', 'it', 'To', 'A'),
('150242be8c00f6', 'it', 'HOME', 'HOME'),
('150242be8c00f9', 'it', 'Yes', 'Si'),
('150242be8c00fb', 'it', 'Please see your<BR>System Administrator', 'Contatta il tuo amministratore di sistema'),
('150242be8c00ff', 'it', 'SMTP Email Information Not Setup', 'Informazioni Email SMTP non configurate'),
('150242be8c0101', 'it', 'Ok', 'Ok'),
('150242be8c0104', 'it', 'Please input an email address to send to', 'Inserire indirizzo email destinatario'),
('150242be8c0107', 'it', 'Please input valid email address(es) to send to', 'Inserire un indirizzo email destinatario valido'),
('150242be8c010a', 'it', 'Please input an email address to send from', 'Inserire indirizzo email mittente'),
('150242be8c010d', 'it', 'Please input a valid email address to send from', 'Inserire un valido indirizzo email mittente'),
('150242be8c010f', 'it', 'Please input a filename', 'Inserire il nome di un file'),
('15029972f2bac7', 'it', 'You do not have access', 'Non sei autorizzato ad accedere...'),
('15029941c9cc41', 'it', 'you have been logged out', 'Sei stato disconnesso...'),
('150299f3d1c36f', 'it', 'Report has Expired', 'Il report è scaduto...'),
('150299ff3507ed', 'it', 'No Such Report', 'Report inesistente...');
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Translation in nuBuilder 2.7.4.3

Unread post by admin »

Thanks

Steven
Locked