[Vtigercrm-developers] Where do the variables in MailParse.php come from?

Minnie minnie at vtiger.com
Wed Jul 18 00:14:21 PDT 2007


Dear Tzenk,

          To give i18n support in JAVASCRIPT files, we have included a js file called en_us.lang.js under include/js directory. As we have included this js file in Smarty/templates/Header.tpl file, the javascript array alert_arr is accessible globally. so you need to put an KEY(label)-VALUE entry in this file and use that label  in the place of hardcoded string in javascript files.

To remove hardcoded string in MailParse.php, kindly follow given steps here.
1)Include entries for hardcode strings in modules/Webmails/language/en_us.lang.php
2)Do the global declaration of $mod_strings variable in MailParse.php file.
3)Replace all the hardcoded strings with repective labels.

I hope this will be helpful for you. 
Kindly get back to me if you need any clarification.

Thanks & Regards,
Minnie.
         
----tzenk at gmx.net wrote ---- 

                                                                                    Hi everybody,
i´m working on a way to make all the hardcoded things within the 
MailParse.php i18n compatible.

for example the title=" i want to get into variables. As they are inside 
a javascript string i am quite lost how to do this.
First thing i found out is that i can make

row 67
title="Read"> to
title="'.$num.'">

and it then shows me the content of that $num (the number 2 in this 
case). Now if i would make a variable called $read it would show me 
"Read" and it would be okay since i then could add any translated word 
into the variable. But i wonder and this is my main question from WHERE 
is it getting the $num variable e.g. where do i have to add new 
variables? Can anyone tell me where to look at?


After that addition i want to think about how to tell this variable to 
look in the lang file which is choosen by the user, so one only has to 
translate the included varibles in the lang file within the webmails 
module, but that is another step, just wanted to ask if maybe someone 
else has thought about this too?

TIA




_______________________________________________
Reach hundreds of potential candidates - http://jobs.vtiger.com 

                                                         
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20070718/6386ef71/attachment-0004.html 


More information about the vtigercrm-developers mailing list