Repository: translate/translate

Issue:
po2php does not convert one file among many
Hi
I have a weird situation where I can convert many translated po files to php, but one.

The one in particular (MailManager.po) - when converted from po to php - looses all translation and keeps original translation (english).

MailManager.po file was generated by php2po, as many other files. 

command used is

```
po2php -t templ/MailManager.php -i po/MailManager.po -o MailManager.php
```

po2php version is 1.11.0 (Kubuntu 14.10)

Files are put inline here:

Mailmanager.po

``` pot
#. extracted from templ/MailManager.php
# Olivier Hallot <olivier.hallot@libreoffice.org>, 2014.
msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-11-14 17:22-0200\n"
"PO-Revision-Date: 2014-11-14 17:31-0200\n"
"Last-Translator: Olivier Hallot <olivier.hallot@libreoffice.org>\n"
"Language-Team: Brazilian Portuguese <kde-i18n-pt_BR@kde.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Lokalize 1.5\n"
"Language: pt_BR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. /*+**********************************************************************************
#.  * The contents of this file are subject to the vtiger CRM Public License Version 1.1
#.  * ("License"); You may not use this file except in compliance with the License
#.  * The Original Code is:  vtiger CRM Open Source
#.  * The Initial Developer of the Original Code is vtiger.
#.  * Portions created by vtiger are Copyright (C) vtiger.
#.  * All Rights Reserved.
#.  ************************************************************************************/
#: $languageStrings->'JSLBL_Body_Cannot_Be_Empty'
msgid "Body cannot be empty"
msgstr "O corpo não pode ser vazio"

#: $languageStrings->'LBL_10_MIN'
msgid "10 Minutes"
msgstr "10 Minutos"

#: $languageStrings->'LBL_5_MIN'
msgid "5 Minutes"
msgstr "5 Minutos"

#: $languageStrings->'LBL_Account_Password'
msgid "account password"
msgstr "senha da conta"

#: $languageStrings->'LBL_ACCOUNT_TYPE'
msgid "Account Type"
msgstr "Tipo de conta"

#: $languageStrings->'LBL_ACTIONS'
msgid "Actions"
msgstr "Ações"

#: $languageStrings->'LBL_ADD'
msgid "Add"
msgstr "Adicionar"

#: $languageStrings->'LBL_ALLMAILS'
msgid "All Mails"
msgstr "Todas as mensagens"

#: $languageStrings->'LBL_Associate'
msgid "Associate"
msgstr "Associar"

#: $languageStrings->'LBL_ATTACHMENTS'
msgid "Attachment:"
msgstr "Anexo:"

#: $languageStrings->'LBL_Attachments'
msgid "Attachments"
msgstr "Anexos"

#: $languageStrings->'LBL_BCC'
msgid "BCC"
msgstr "BCC"

#: $languageStrings->'LBL_CANCEL_BUTTON_LABEL'
msgctxt "$languageStrings->'LBL_CANCEL_BUTTON_LABEL'"
msgid "Cancel"
msgstr "Cancelar"

#: $languageStrings->'LBL_Cancel'
msgctxt "$languageStrings->'LBL_Cancel'"
msgid "Cancel"
msgstr "Cancelar"

#: $languageStrings->'LBL_CC'
msgid "CC"
msgstr "CC"

#: $languageStrings->'LBL_Certificate_Validations'
msgid "Certificate Validations"
msgstr "Validações de certificado"

#: $languageStrings->'LBL_CHOOSE_EXISTING_FOLDER'
msgid "Choose an existing folder"
msgstr "Escolha uma pasta existente"

#: $languageStrings->'LBL_CHOOSE_FOLDER'
msgid "Copies of the sent mails for this account will be saved in this folder."
msgstr "Cópias dos e-mails enviados serão salvas nesta pasta."

#: $languageStrings->'LBL_CHOOSE_FOLDER_DESC'
msgid ""
"Copies of the sent mails for this account will be saved in the default <b>"
"Sent Mail</b> folder.<br><br>If you want to change the default sent mail "
"folder, after creating the mail box click on <b>Settings</b> icon and "
"<b>Edit</b> the MailBox."
msgstr ""
"Cópias dos e-mails enviados serão salvas na pasta padrão <b>Enviadas</b>.<br>"
"<br>Se desejar mudar a pasta padrão, depois de cria a caixa postal, clique no "
"ícone  <b>Configurações</b> e <b>edite</b> a caixa postal."

#: $languageStrings->'LBL_Compose'
msgid "Compose"
msgstr "Redigir"

#: $languageStrings->'LBL_Create_Contact'
msgid "Create contact"
msgstr "Criar contato"

#: $languageStrings->'LBL_CREATE_MAILBOX'
msgid "Create Mailbox"
msgstr "Criar caixa postal"

#: $languageStrings->'LBL_Date'
msgid "Date"
msgstr "Data"

#: $languageStrings->'LBL_Delete'
msgctxt "$languageStrings->'LBL_Delete'"
msgid "Delete"
msgstr "Excluir"

#: $languageStrings->'LBL_DELETE_Mailbox'
msgid "Delete Mailbox"
msgstr "Excluir caixa postal"

#: $languageStrings->'LBL_Do_Not_Validate_Cert'
msgid "Do not validate cert"
msgstr "Não validar o certificado"

#: $languageStrings->'LBL_Drafts'
msgctxt "$languageStrings->'LBL_Drafts'"
msgid "Drafts"
msgstr "Rascunhos"

#: $languageStrings->'LBL_EMAIL_TEMPLATES_LIST'
msgid "Email Templates"
msgstr "Modelos de e-mail"

#: $languageStrings->'LBL_FIND'
msgid "Find"
msgstr "Localizar"

#: $languageStrings->'LBL_Folders'
msgid "Folders"
msgstr "Pastas"

#: $languageStrings->'LBL_Forward'
msgid "Forward"
msgstr "Encaminhar"

#: $languageStrings->'LBL_FROM'
msgid "From"
msgstr "De"

#: $languageStrings->'LBL_Go_Back'
msgid "Back"
msgstr "Voltar"

#: $languageStrings->'LBL_Imap2'
msgid "IMAP2"
msgstr "IMAP2"

#: $languageStrings->'LBL_Imap4'
msgid "IMAP4"
msgstr "IMAP4"

#: $languageStrings->'LBL_IN'
msgid "in"
msgstr "em"

#: $languageStrings->'LBL_Like'
msgid "like"
msgstr "like"

#: $languageStrings->'LBL_MAILBOX_DETAILS'
msgid "Mailbox Details"
msgstr "Detalhes da caixa postal"

#: $languageStrings->'LBL_Mailbox'
msgid "Mailbox"
msgstr "Caixa postal"

#: $languageStrings->'LBL_MAILMANAGER_ADD_Accounts'
msgid "Add Organization"
msgstr "Criar organização"

#: $languageStrings->'LBL_MAILMANAGER_ADD_Calendar'
msgid "Add Event/To Do"
msgstr "Criar Compromisso / Tarefa"

#: $languageStrings->'LBL_MAILMANAGER_ADD_Contacts'
msgid "Add Contact"
msgstr "Criar contato"

#: $languageStrings->'LBL_MAILMANAGER_ADD_Emails'
msgid "Attach Email"
msgstr "Anexar e-mail"

#: $languageStrings->'LBL_MAILMANAGER_ADD_HelpDesk'
msgid "Add Ticket"
msgstr "Criar ticket"

#: $languageStrings->'LBL_MAILMANAGER_ADD_Leads'
msgid "Add Lead"
msgstr "Criar lead"

#: $languageStrings->'LBL_MAILMANAGER_ADD_ModComments'
msgctxt "$languageStrings->'LBL_MAILMANAGER_ADD_ModComments'"
msgid "Add Comment"
msgstr "Adicionar comentário"

#: $languageStrings->'LBL_Mail_Server'
msgid "Mail Server Name or IP"
msgstr "Nome ou IP do servidor"

#: $languageStrings->'LBL_Mark_As_Unread'
msgid "Mark as unread"
msgstr "Marcar como não lido"

#: $languageStrings->'LBL_MODULE_DENIED'
msgid "module denied!"
msgstr "módulo negado!"

#: $languageStrings->'LBL_MODULE_DESCRIPTION'
msgid ""
"Mail Manager is an integrated email client that allows users to perform CRM "
"related actions on incoming email. It helps you create Leads, Contacts, "
"Organizations, Trouble Tickets and To Dos from the emails that you receive "
"in your inbox. Should sender's email id match with a record in vtiger CRM, "
"you can perform more actions like, Attaching email, Adding To do, Comment "
"and Ticket. Additionally, you can manage composing, replying, forwarding "
"emails etc."
msgstr ""
"O gestor de mensagens é um cliente de e-mail que permite aos usuários "
"executarem ações de relacionamento com clientes nos e-mails de entrada. Ele "
"ajuda a criar leads, Contatos, organizações, tickets e tarefas a partir dos "
"e-mails de sua caixa de entrada. Se um dos remetentes conferir com um "
"registro presente no CRM, você poderá executar mais ações tais como anexar um "
"e-mail, criar uma tarefa, um comentário ou um ticket. Além disso, você pode "
"gerenciar a composição de e-mails, responder, encaminhar  e-mails."

#: $languageStrings->'LBL_MOVE_TO'
msgid "Move To..."
msgstr "Mover para..."

#: $languageStrings->'LBL_Newer'
msgid "Newer"
msgstr "Mais novas"

#: $languageStrings->'LBL_Next'
msgid "next"
msgstr "próximo"

#: $languageStrings->'LBL_NO_EMAILS_SELECTED'
msgctxt "$languageStrings->'LBL_NO_EMAILS_SELECTED'"
msgid "No Emails Selected."
msgstr "Sem e-mails selecionados"

#: $languageStrings->'LBL_No_Mails_Found'
msgid "No mails found."
msgstr "Nenhum e-mail encontrado."

#: $languageStrings->'LBL_No_Matching_Record_Found'
msgid "No matching records found."
msgstr "Nenhum registro encontrado."

#: $languageStrings->'LBL_NONE'
msgid "None"
msgstr "Nenhum"

#: $languageStrings->'LBL_No_TLS'
msgid "No TLS"
msgstr "Sem TLS"

#: $languageStrings->'LBL_Older'
msgid "Older"
msgstr "Mais antigo"

#: $languageStrings->'LBL_Outbox'
msgid "CRM Outbox"
msgstr "Caixa de saída do CRM"

#: $languageStrings->'LBL_Password'
msgid "Password"
msgstr "Senha"

#: $languageStrings->'LBL_Previous'
msgid "previous"
msgstr "anterior"

#: $languageStrings->'LBL_Print'
msgid "Print"
msgstr "Imprimir"

#: $languageStrings->'LBL_Protocol'
msgid "Protocol"
msgstr "Protocolo"

#: $languageStrings->'LBL_READ_ACCESS_FOR'
msgid "Read access for"
msgstr "Acesso de leitura para"

#: $languageStrings->'LBL_Refresh'
msgid "Refresh"
msgstr "Atualizar"

#: $languageStrings->'LBL_REFRESH_TIME'
msgid "Refresh Time"
msgstr "Intervalo de atualização"

#: $languageStrings->'LBL_RELATED_RECORDS'
msgid "Related Records"
msgstr "Registros relacionados"

#: $languageStrings->'LBL_Remove'
msgid "Remove"
msgstr "Remover"

#: $languageStrings->'LBL_Reply_All'
msgid "Reply all"
msgstr "Responder a todos"

#: $languageStrings->'LBL_Reply'
msgid "Reply"
msgstr "Responder"

#: $languageStrings->'LBL_SAVE_BUTTON_LABEL'
msgid "Save"
msgstr "Salvar"

#: $languageStrings->'LBL_SAVE_NOW'
msgid "Save Now"
msgstr "Salvar agora"

#: $languageStrings->'LBL_Search'
msgid "Search"
msgstr "Pesquisar"

#: $languageStrings->'LBL_SELECT_ACCOUNT_TYPE'
msgid "Select Organization Type"
msgstr "Selecionar o tipo de organização"

#: $languageStrings->'LBL_SELECT_DOCUMENTS'
msgid "Select Documents"
msgstr "Selecionar documentos"

#: $languageStrings->'LBL_SELECTED_FOLDER'
msgid "Selected Folder"
msgstr "Selecionar pasta"

#: $languageStrings->'LBL_SELECT_EMAIL_TEMPLATE'
msgid "Select Email template"
msgstr "Selecionar modelo de e-mail"

#: $languageStrings->'LBL_Send'
msgid "Send"
msgstr "Enviar"

#: $languageStrings->'LBL_SENT_MAILS'
msgid "Sent Mails"
msgstr "E-mails enviados"

#: $languageStrings->'LBL_SSL_Options'
msgid "SSL Options"
msgstr "Opções SSL"

#: $languageStrings->'LBL_SSL'
msgid "SSL"
msgstr "SSL"

#: $languageStrings->'LBL_SUBJECT'
msgid "Subject"
msgstr "Assunto"

#: $languageStrings->'LBL_TLS'
msgid "TLS"
msgstr "TLS"

#: $languageStrings->'LBL_TO_ACCOUNTS'
msgid "To Organizations"
msgstr "Para organizações"

#: $languageStrings->'LBL_TO_CONTACTS'
msgid "To Contacts"
msgstr "Para contatos"

#: $languageStrings->'LBL_TO_LEADS'
msgid "To Leads"
msgstr "Para leads"

#: $languageStrings->'LBL_TO'
msgid "To"
msgstr "Para"

#: $languageStrings->'LBL_TO_USERS'
msgid "To Users"
msgstr "Para usuários"

#: $languageStrings->'LBL_Username'
msgid "User Name"
msgstr "Nome de login"

#: $languageStrings->'LBL_Validate_Cert'
msgid "Validate cert"
msgstr "Validar o certificado"

#: $languageStrings->'LBL_WRITE_ACCESS_FOR'
msgid "Write access for"
msgstr "Acesso de escrita para"

#: $languageStrings->'LBL_WRITE_YOUR_COMMENT_HERE'
msgid "Add your comment here ..."
msgstr "Adicione seus comentários aqui ..."

#: $languageStrings->'LBL_Your_Mailbox_Account'
msgid "your mailbox account"
msgstr "sua conta de correio"

#: $languageStrings->'MailManager'
msgctxt "$languageStrings->'MailManager'"
msgid "Mail Manager"
msgstr "Gestor de mensagens"

#: $jsLanguageStrings->'JS_FUTURE_EVENT_CANNOT_BE_HELD'
msgid "Cannot Be Held For Future"
msgstr "Cannot Be Held For Future"

#: $jsLanguageStrings->'JSLBL_ACCOUNTNAME_CANNOT_EMPTY'
msgid "Organization Name cannot be empty"
msgstr "O nome da organização não pode ser vazio"

#: $jsLanguageStrings->'JSLBL_ADD_COMMENT'
msgctxt "$jsLanguageStrings->'JSLBL_ADD_COMMENT'"
msgid "Add Comment"
msgstr "Adicionar comentário"

#: $jsLanguageStrings->'JSLBL_Associating'
msgid "Associating"
msgstr "Associando"

#: $jsLanguageStrings->'JSLBL_ATTACHMENT_NOT_DELETED'
msgid "Attachment could not be deleted"
msgstr "Não foi possível excluir o anexo"

#: $jsLanguageStrings->'JSLBL_CANNOT_ADD_EMPTY_COMMENT'
msgid "Comment cannot be empty"
msgstr "O comentário não pode ser vazio"

#: $jsLanguageStrings->'JSLBL_CC'
msgid "Cc: "
msgstr "CC: "

#: $jsLanguageStrings->'JSLBL_Choose_Server_Type'
msgid "Choose server type"
msgstr "Escolha o tipo de servidor"

#: $jsLanguageStrings->'JSLBL_DATE'
msgid "Date: "
msgstr "Data: "

#: $jsLanguageStrings->'JSLBL_Delete_Confirm'
msgid "Do you want to delete the Emails permanently?"
msgstr "Deseja excluir os e-mails permanentemente?"

#: $jsLanguageStrings->'JSLBL_Delete'
msgctxt "$jsLanguageStrings->'JSLBL_Delete'"
msgid "Delete"
msgstr "Excluir"

#: $jsLanguageStrings->'JSLBL_Delete_Mails_Confirm'
msgid "Do you want to delete the Emails?"
msgstr "Deseja excluir os e-mails?"

#: $jsLanguageStrings->'JSLBL_Deleting'
msgid "Deleting"
msgstr "Excluindo"

#: $jsLanguageStrings->'JSLBL_DRAFT_MAIL_SAVED'
msgid "Mail is saved under Drafts"
msgstr "Mensagem salva nos rascunhos"

#: $jsLanguageStrings->'JSLBL_Drafts'
msgctxt "$jsLanguageStrings->'JSLBL_Drafts'"
msgid "Drafts"
msgstr "Rascunhos"

#: $jsLanguageStrings->'JSLBL_EMAIL_FORMAT_INCORRECT'
msgid "Please provide proper email address"
msgstr "Forneça o endereço apropriado"

#: $jsLanguageStrings->'JSLBL_ENTER_SOME_VALUE'
msgid "Enter some string to search"
msgstr "Digite um texto a pesquisar"

#: $jsLanguageStrings->'JSLBL_Failed_To_Open_Mail'
msgid "Failed to open the mail"
msgstr "Falhou ao abrir o e-mail"

#: $jsLanguageStrings->'JSLBL_Failed_To_Save_Mail'
msgid "Failed to save the mail"
msgstr "Falhou ao salvar o e-mail"

#: $jsLanguageStrings->'JSLBL_Failed_To_Send_Mail'
msgid "Failed to send the mail"
msgstr "Falhou ao enviar o e-mail"

#: $jsLanguageStrings->'JSLBL_Fastmail'
msgid "Fastmail"
msgstr "Fastmail"

#: $jsLanguageStrings->'JSLBL_FILEUPLOAD_LIMIT_EXCEEDED'
msgid "File Upload Limit exceeded!!"
msgstr "Excedeu o limite de tamanho para gravação!"

#: $jsLanguageStrings->'JSLBL_Finding_Relation'
msgid "Finding relation"
msgstr "Buscando relação"

#: $jsLanguageStrings->'JSLBL_Find_Relation_Now'
msgid "Find relation now"
msgstr "Buscar a relação agora"

#: $jsLanguageStrings->'JSLBL_FORWARD_MESSAGE_TEXT'
msgid "---------- Forwarded message ----------"
msgstr "---------- Mensagem encaminhada ----------"

#: $jsLanguageStrings->'JSLBL_FROM'
msgid "From:"
msgstr "De:"

#: $jsLanguageStrings->'JSLBL_Gmail'
msgid "Gmail"
msgstr "Gmail"

#: $jsLanguageStrings->'JSLBL_LOADING_FOLDERS'
msgid "Loading Folders.."
msgstr "Carregando pastas..."

#: $jsLanguageStrings->'JSLBL_Loading'
msgid "Loading"
msgstr "Carregando"

#: $jsLanguageStrings->'JSLBL_Loading_Please_Wait'
msgid "Loading Please Wait"
msgstr "Carregando, aguarde por favor."

#: $jsLanguageStrings->'JSLBL_MAIL_MOVED'
msgid "Mail(s) moved"
msgstr "Mensagem(ns) movidas"

#: $jsLanguageStrings->'JSLBL_MAIL_SENT'
msgid "Mail Sent"
msgstr "Mensagem enviada"

#: $jsLanguageStrings->'JSLBL_MOVING'
msgid "Moving Mail(s)"
msgstr "Movendo mensagem(ns)"

#: $jsLanguageStrings->'JSLBL_NO_EMAILS_SELECTED'
msgctxt "$jsLanguageStrings->'JSLBL_NO_EMAILS_SELECTED'"
msgid "No Emails Selected."
msgstr "Sem e-mails selecionados"

#: $jsLanguageStrings->'JSLBL_NO_MATCH'
msgid "No match found"
msgstr "Sem resultados"

#: $jsLanguageStrings->'JSLBL_Nothing_Found'
msgid "Nothing found"
msgstr "Nada encontrado"

#: $jsLanguageStrings->'JSLBL_Opening'
msgid "Opening"
msgstr "Abrindo"

#: $jsLanguageStrings->'JSLBL_Other'
msgid "Other"
msgstr "Outro"

#: $jsLanguageStrings->'JSLBL_PASSWORD_CANNOT_BE_EMPTY'
msgid "Password cannot be empty"
msgstr "A senha não pode ser vazia"

#: $jsLanguageStrings->'JSLBL_PLEASE_SELECT_ATLEAST_ONE_MAIL'
msgid "Please select at least one mail"
msgstr "Selecione pelo menos uma mensagem"

#: $jsLanguageStrings->'JSLBL_PLEASE_SELECT_ATLEAST_ONE_RECORD'
msgid "Please select at least one record"
msgstr "Selecione pelo menos um registro"

#: $jsLanguageStrings->'JSLBL_Receipents_Warning_Message'
msgid "Please select recepients"
msgstr "Selecione os destinatários"

#: $jsLanguageStrings->'JSLBL_Recepient_Cannot_Be_Empty'
msgid "Recepient (To) cannot be empty"
msgstr "O destinatário (Para) não pode estar vazio"

#: $jsLanguageStrings->'JSLBL_Removing'
msgid "Removing"
msgstr "Removendo"

#: $jsLanguageStrings->'JSLBL_Replied'
msgid "Replied"
msgstr "Respondido"

#: $jsLanguageStrings->'JSLBL_SaveWith_EmptySubject'
msgid "Save with subject empty?"
msgstr "Salvar com assunto em branco?"

#: $jsLanguageStrings->'JSLBL_Saving_And_Verifying'
msgid "Saving & Verifying"
msgstr "Salvando e verificando"

#. Duplicated key-value pairs
#: $jsLanguageStrings->'JSLBL_Saving'
msgid "Saving"
msgstr "Salvando"

#: $jsLanguageStrings->'JSLBL_Search_For_Email'
msgid "Search for email"
msgstr "Pesquisar por e-mail"

#: $jsLanguageStrings->'JSLBL_Searching_Please_Wait'
msgid "Searching Please Wait"
msgstr "Pesquisando. Aguarde."

#: $jsLanguageStrings->'JSLBL_Searching'
msgid "Searching"
msgstr "Pesquisando"

#: $jsLanguageStrings->'JSLBL_Sending'
msgid "Sending"
msgstr "Enviando"

#: $jsLanguageStrings->'JSLBL_SERVERNAME_CANNOT_BE_EMPTY'
msgid "Server Name cannot be empty"
msgstr "O nome do servidor não pode ser vazio"

#: $jsLanguageStrings->'JSLBL_Settings'
msgid "Settings"
msgstr "Configurações"

#: $jsLanguageStrings->'JSLBL_Subject_Cannot_Be_Empty'
msgid "Subject cannot be empty"
msgstr "O assunto não pode estar em branco"

#: $jsLanguageStrings->'JSLBL_SUBJECT'
msgid "Subject: "
msgstr "Assunto: "

#: $jsLanguageStrings->'JSLBL_TO'
msgid "To: "
msgstr "Para: "

#: $jsLanguageStrings->'JSLBL_Updating'
msgid "Updating"
msgstr "Atualizando"

#: $jsLanguageStrings->'JSLBL_UPLOAD_CANCEL'
msgctxt "$jsLanguageStrings->'JSLBL_UPLOAD_CANCEL'"
msgid "Cancel"
msgstr "Cancelar"

#: $jsLanguageStrings->'JSLBL_UPLOAD_DELETE'
msgid "[x]"
msgstr "[x]"

#: $jsLanguageStrings->'JSLBL_UPLOAD_DROPFILES'
msgid "Drop files here to upload"
msgstr "Solte os arquivos aqui para gravar"

#: $jsLanguageStrings->'JSLBL_UPLOAD_FAILED'
msgid "Failed"
msgstr "Falhou"

#: $jsLanguageStrings->'JSLBL_UPLOAD_FILE'
msgid "Upload"
msgstr "Gravar"

#: $jsLanguageStrings->'JSLBL_USERNAME_CANNOT_BE_EMPTY'
msgid "User Name cannot be empty"
msgstr "O nome de login não pode ser vazio"

#: $jsLanguageStrings->'JSLBL_Yahoo'
msgid "Yahoo"
msgstr "Yahoo"

#: $jsLanguageStrings->'MailManager'
msgctxt "$jsLanguageStrings->'MailManager'"
msgid "Mail Manager"
msgstr "Gestor de mensagens"

```

MailManager.php (orig)

``` php
<?php
/*+**********************************************************************************
 * The contents of this file are subject to the vtiger CRM Public License Version 1.1
 * ("License"); You may not use this file except in compliance with the License
 * The Original Code is:  vtiger CRM Open Source
 * The Initial Developer of the Original Code is vtiger.
 * Portions created by vtiger are Copyright (C) vtiger.
 * All Rights Reserved.
 ************************************************************************************/

$languageStrings = Array (
    'JSLBL_Body_Cannot_Be_Empty' => 'Body cannot be empty',
    'LBL_10_MIN' => '10 Minutes',
    'LBL_5_MIN' => '5 Minutes',
    'LBL_Account_Password'     => 'account password',
    'LBL_ACCOUNT_TYPE' => 'Account Type',
    'LBL_ACTIONS'         => 'Actions',
    'LBL_ADD' => 'Add',
    'LBL_ALLMAILS' => 'All Mails',
    'LBL_Associate'       => 'Associate',
    'LBL_ATTACHMENTS'  =>'Attachment:',
    'LBL_Attachments' => 'Attachments',
    'LBL_BCC'         => 'BCC',
    'LBL_CANCEL_BUTTON_LABEL' => 'Cancel',
    'LBL_Cancel'          => 'Cancel',
    'LBL_CC'          => 'CC',
    'LBL_Certificate_Validations' => 'Certificate Validations',
    'LBL_CHOOSE_EXISTING_FOLDER' => 'Choose an existing folder',
    'LBL_CHOOSE_FOLDER' => 'Copies of the sent mails for this account will be saved in this folder.',
    'LBL_CHOOSE_FOLDER_DESC' => 'Copies of the sent mails for this account will be saved in the default <b>Sent Mail</b> folder.<br><br>If you want to change the default sent mail folder, after creating the mail box click on <b>Settings</b> icon and <b>Edit</b> the MailBox.',
    'LBL_Compose'         => 'Compose',
    'LBL_Create_Contact'  => 'Create contact',
    'LBL_CREATE_MAILBOX' => 'Create Mailbox',
    'LBL_Date'        => 'Date',
    'LBL_Delete'          =>  'Delete',
    'LBL_DELETE_Mailbox' => 'Delete Mailbox',
    'LBL_Do_Not_Validate_Cert'    => 'Do not validate cert',
    'LBL_Drafts'=>'Drafts',
    'LBL_EMAIL_TEMPLATES_LIST'=>'Email Templates',
    'LBL_FIND'=>'Find',
    'LBL_Folders'         => 'Folders',
    'LBL_Forward'         => 'Forward',
    'LBL_FROM'        => 'From',
    'LBL_Go_Back'         => 'Back',
    'LBL_Imap2'       => 'IMAP2',
    'LBL_Imap4'       => 'IMAP4',
    'LBL_IN' =>'in',
    'LBL_Like'            => 'like',
    'LBL_MAILBOX_DETAILS' => 'Mailbox Details',
    'LBL_Mailbox'         => 'Mailbox',
    'LBL_MAILMANAGER_ADD_Accounts' => 'Add Organization',
    'LBL_MAILMANAGER_ADD_Calendar' => 'Add Event/To Do',
    'LBL_MAILMANAGER_ADD_Contacts' => 'Add Contact',
    'LBL_MAILMANAGER_ADD_Emails' => 'Attach Email',
    'LBL_MAILMANAGER_ADD_HelpDesk' => 'Add Ticket',
    'LBL_MAILMANAGER_ADD_Leads' => 'Add Lead',
    'LBL_MAILMANAGER_ADD_ModComments' => 'Add Comment',
    'LBL_Mail_Server'     => 'Mail Server Name or IP',
    'LBL_Mark_As_Unread'  => 'Mark as unread',
    'LBL_MODULE_DENIED' => 'module denied!',
    'LBL_MODULE_DESCRIPTION' => "Mail Manager is an integrated email client that allows users to perform CRM related actions on incoming email. It helps you create Leads, Contacts, Organizations, Trouble Tickets and To Dos from the emails that you receive in your inbox. Should sender's email id match with a record in vtiger CRM, you can perform more actions like, Attaching email, Adding To do, Comment and Ticket. Additionally, you can manage composing, replying, forwarding emails etc.",
    'LBL_MOVE_TO'=>'Move To...',
    'LBL_Newer'           => 'Newer',
    'LBL_Next'            => 'next',
    'LBL_NO_EMAILS_SELECTED' => 'No Emails Selected.',
    'LBL_No_Mails_Found'  => 'No mails found.',
    'LBL_No_Matching_Record_Found' => 'No matching records found.',
    'LBL_NONE' => 'None',
    'LBL_No_TLS'      => 'No TLS',
    'LBL_Older'           => 'Older',
    'LBL_Outbox'          => 'CRM Outbox',
    'LBL_Password'             => 'Password',
    'LBL_Previous'        => 'previous',
    'LBL_Print' => 'Print',
    'LBL_Protocol'    => 'Protocol',
    'LBL_READ_ACCESS_FOR'   =>'Read access for',
    'LBL_Refresh'         => 'Refresh',
    'LBL_REFRESH_TIME'=>'Refresh Time',
    'LBL_RELATED_RECORDS' => 'Related Records',
    'LBL_Remove'          => 'Remove',
    'LBL_Reply_All'       => 'Reply all',
    'LBL_Reply'           => 'Reply',
    'LBL_SAVE_BUTTON_LABEL' => 'Save',
    'LBL_SAVE_NOW'=>'Save Now',
    'LBL_Search'          => 'Search',
    'LBL_SELECT_ACCOUNT_TYPE'     => 'Select Organization Type',
    'LBL_SELECT_DOCUMENTS'=>'Select Documents',
    'LBL_SELECTED_FOLDER' => 'Selected Folder',
    'LBL_SELECT_EMAIL_TEMPLATE'=>'Select Email template',
    'LBL_Send'            => 'Send',
    'LBL_SENT_MAILS' => 'Sent Mails',
    'LBL_SSL_Options' => 'SSL Options',
    'LBL_SSL'         => 'SSL',
    'LBL_SUBJECT'   =>  'Subject',
    'LBL_TLS'         => 'TLS',
    'LBL_TO_ACCOUNTS' => 'To Organizations',
    'LBL_TO_CONTACTS' => 'To Contacts',
    'LBL_TO_LEADS' => 'To Leads',
    'LBL_TO'          => 'To',
    'LBL_TO_USERS' => 'To Users',
    'LBL_Username'             => 'User Name',
    'LBL_Validate_Cert'           => 'Validate cert',
    'LBL_WRITE_ACCESS_FOR'  =>'Write access for',
    'LBL_WRITE_YOUR_COMMENT_HERE' => 'Add your comment here ...',
    'LBL_Your_Mailbox_Account' => 'your mailbox account',
    'MailManager' => 'Mail Manager',
);

$jsLanguageStrings = Array (
    'JS_FUTURE_EVENT_CANNOT_BE_HELD' => 'Cannot Be Held For Future',
    'JSLBL_ACCOUNTNAME_CANNOT_EMPTY'=>'Organization Name cannot be empty',
    'JSLBL_ADD_COMMENT'=>'Add Comment',
    'JSLBL_Associating'          => 'Associating',
    'JSLBL_ATTACHMENT_NOT_DELETED'  =>  'Attachment could not be deleted',
    'JSLBL_CANNOT_ADD_EMPTY_COMMENT' => 'Comment cannot be empty',
    'JSLBL_CC'=>'Cc: ',
    'JSLBL_Choose_Server_Type'        => 'Choose server type',
    'JSLBL_DATE'=>'Date: ',
    'JSLBL_Delete_Confirm'            =>'Do you want to delete the Emails permanently?',
    'JSLBL_Delete'            =>  'Delete',
    'JSLBL_Delete_Mails_Confirm'      =>'Do you want to delete the Emails?',
    'JSLBL_Deleting'              => 'Deleting',  
    'JSLBL_DRAFT_MAIL_SAVED'=>'Mail is saved under Drafts',
    'JSLBL_Drafts'=>'Drafts',
    'JSLBL_EMAIL_FORMAT_INCORRECT'=>'Please provide proper email address',
    'JSLBL_ENTER_SOME_VALUE' => 'Enter some string to search',
    'JSLBL_Failed_To_Open_Mail'  => 'Failed to open the mail',
    'JSLBL_Failed_To_Save_Mail'     =>  'Failed to save the mail',
    'JSLBL_Failed_To_Send_Mail'  => 'Failed to send the mail',
    'JSLBL_Fastmail'                  => 'Fastmail',
    'JSLBL_FILEUPLOAD_LIMIT_EXCEEDED'=>'File Upload Limit exceeded!!',
    'JSLBL_Finding_Relation'     => 'Finding relation',
    'JSLBL_Find_Relation_Now'    => 'Find relation now',
    'JSLBL_FORWARD_MESSAGE_TEXT'=>'---------- Forwarded message ----------',
    'JSLBL_FROM'=>'From:',
    'JSLBL_Gmail'                     => 'Gmail',
    'JSLBL_LOADING_FOLDERS' => 'Loading Folders..',
    'JSLBL_Loading'              => 'Loading',
    'JSLBL_Loading_Please_Wait'  => 'Loading Please Wait',
    'JSLBL_MAIL_MOVED'=>'Mail(s) moved',
    'JSLBL_MAIL_SENT'=>'Mail Sent',
    'JSLBL_MOVING'=>'Moving Mail(s)',
    'JSLBL_NO_EMAILS_SELECTED' => 'No Emails Selected.',
    'JSLBL_NO_MATCH'                  => 'No match found',
    'JSLBL_Nothing_Found'             => 'Nothing found',
    'JSLBL_Opening'              => 'Opening',
    'JSLBL_Other'                     => 'Other',
    'JSLBL_PASSWORD_CANNOT_BE_EMPTY'=>'Password cannot be empty',
    'JSLBL_PLEASE_SELECT_ATLEAST_ONE_MAIL'=>'Please select at least one mail',
    'JSLBL_PLEASE_SELECT_ATLEAST_ONE_RECORD'=>'Please select at least one record',
    'JSLBL_Receipents_Warning_Message'=>'Please select recepients',
    'JSLBL_Recepient_Cannot_Be_Empty' => 'Recepient (To) cannot be empty',
    'JSLBL_Removing'                  => 'Removing',
    'JSLBL_Replied'              => 'Replied',
    'JSLBL_SaveWith_EmptySubject'=>'Save with subject empty?',
    'JSLBL_Saving_And_Verifying' => 'Saving & Verifying',
    'JSLBL_Saving'                  => 'Saving', //Duplicated key-value pairs
    'JSLBL_Search_For_Email'          => 'Search for email',
    'JSLBL_Searching_Please_Wait'=> 'Searching Please Wait',
    'JSLBL_Searching'            => 'Searching',
    'JSLBL_Sending'              => 'Sending',
    'JSLBL_SERVERNAME_CANNOT_BE_EMPTY'=>'Server Name cannot be empty',
    'JSLBL_Settings'             => 'Settings',
    'JSLBL_Subject_Cannot_Be_Empty'     => 'Subject cannot be empty',
    'JSLBL_SUBJECT'=>'Subject: ',
    'JSLBL_TO'=>'To: ',
    'JSLBL_Updating'             => 'Updating',
    'JSLBL_UPLOAD_CANCEL'   => 'Cancel',
    'JSLBL_UPLOAD_DELETE'=>'[x]',
    'JSLBL_UPLOAD_DROPFILES'=>'Drop files here to upload',
    'JSLBL_UPLOAD_FAILED'=>'Failed',
    'JSLBL_UPLOAD_FILE'=>'Upload',
    'JSLBL_USERNAME_CANNOT_BE_EMPTY'=>'User Name cannot be empty',
    'JSLBL_Yahoo'=>'Yahoo',
    'MailManager' => 'Mail Manager',
);

//Special Handling: Mix of language strings are used.
$languageStrings = array_merge($languageStrings, $jsLanguageStrings);
```



Discussion:

Resolving patch:
diff --git a/translate/convert/po2php.py b/translate/convert/po2php.py
--- a/translate/convert/po2php.py
+++ b/translate/convert/po2php.py
@@ -73,7 +73,7 @@ def convertline(self, line):
         # otherwise, this could be a comment
         elif line.strip()[:2] == '//' or line.strip()[:2] == '/*':
             returnline = quote.rstripeol(line) + eol
-        elif line.find('array(') != -1:
+        elif line.lower().replace(" ", "").find('array(') != -1:
             self.inarray = True
             self.prename = line[:line.find('=')].strip() + "->"
             self.equaldel = "=>"


Test patch: