[Vtigercrm-developers] Substr function and unicode
Prasad
prasad at vtiger.com
Tue Apr 1 05:04:45 PDT 2008
Hi Denys,
Thank you for keep us updated on your work.
You can update the comments on the trac ticket:
http://trac.vtiger.com/cgi-bin/trac.cgi/ticket/5245 with your findings.
Also please create new tickets for other issues you have mentioned and
suggest the fix also, this could be helpful
for us and community.
Regards,
Prasad
vtiger Team
On 4/1/08, Денис Потапов <denys.potapov at gmail.com> wrote:
>
> Hi Prasad,
>
>
>
> I'm working with Russian language pack and met some problems.
>
> Till now I've noticed 5 bugs with strlen and substr. I'll ready to fix
> them using Vtiger track, but i ask you to include the phputf8 library (
> http://phputf8.sourceforge.net/ ) into the vtiger core
> (vtigerCRM\include\phputf8). It work's fine on many projects (for example
> Joomla!), and it doing well with VTiger.
>
> The other thing that by default the GraphUtils.php uses Vera font:
> line 27: DEFINE("FF_FONT1",'Vera');
> but it has no Cyrillic support. Probably it's better to change it to
> Arial. Will it be right if I add this issue on track.
>
> The last thing I think deals with any localisation. In Smarty Template
> 'Smarty/templates/ListViewEntries.tpl':
> line 135: {$APP.LBL_NO} {$APP.$MODULE_CREATE}s {$APP.LBL_FOUND} !
> line 172: {$APP.LBL_NO} {$APP.$MODULE_CREATE}s {$APP.LBL_FOUND}
> !</span></td>
> In both cases the plural form is added in template, that is absolutely
> unsuitable for localisation.
>
> For now we solve it by adding all this core (and template) files to
> language pack that is totally incorrect. What can be the solution?
>
>
>
>
> Best regards,
> Denys Potapov
>
>
>
>
>
>
>
>
>
>
> 2008/3/26, Prasad <prasad at vtiger.com>:
> >
> > Hi Denys,
> >
> > To use mb_strlen and mb_substr you need to enable mb_string php
> > extension.
> >
> > Also check out this library: http://phputf8.sourceforge.net/ which has
> > wrapper functions: http://phputf8.sourceforge.net/#String_Functions
> >
> > If you work with this, kindly let us know your observations in more
> > details.
> >
> > Good luck.
> >
> > Regards,
> > Prasad
> >
> >
> > On 3/25/08, ????? ??????? <denis0712 at mail.ru> wrote:
> > >
> > > Hi all!
> > >
> > >
> > > I'm using vtiger CRM 5.0.4 with Russian language Pack.
> > >
> > > I've noticed a bug in "\modules\Leads\ListViewTop.php" on line 115:
> > >
> > > $Top_Leads = (strlen($lead['leadname']) > 20) ?
> > > (substr($lead['leadname'],0,20).'...') : $lead['leadname'];
> > >
> > > Neither "substr" nor "strlen" work correct with Unicode chars.
> > >
> > > I found a solution, to use mb_strlen and mb_substr. Is it suitable to
> > > use
> > > this functions or there are some other suggestions how to fix it?
> > >
> > >
> > >
> > >
> > >
> > >
> > > Best regards,
> > > Denys Potapov
> > >
> > > _______________________________________________
> > >
> > > Reach hundreds of potential candidates - http://jobs.vtiger.com
> > >
> >
> >
> > _______________________________________________
> > Reach hundreds of potential candidates - http://jobs.vtiger.com
> >
>
>
> _______________________________________________
> 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/20080401/2584e57e/attachment-0003.html
More information about the vtigercrm-developers
mailing list