You are here: Re: [SMARTY] Problem with languages « Smarty Templates Posts « IT news, forums, messages
Re: [SMARTY] Problem with languages

Posted by Messju Mohr on 09/30/68 11:13

On Wed, Apr 13, 2005 at 11:00:03PM -0400, Mario St-Gelais wrote:
> I tried to use html_select_date without much success. In my case, I
> wanted the month to appear in French.

Ask your system administrator to enable french locale settings for
you.

> So on my entry form i did :
>
> <select name=selected_day_id>
> {html_options values=$day_id
> selected=$selected_day_id output=$day_id}
> </select>
> <select name=selected_month_id>
> {html_options values=$month_id
> selected=$selected_month_id output=$month_name}
> </select>
> <select name=selected_year_id>
> {html_options values=$year_id
> selected=$selected_year_id output=$year_id}
> </select>
> {assign var="ddn"
>
> value="$selected_month_id,$selected_day_id,$selected_year_id"}
>
> It is basically one html_option for each of day of the month, month of
> the year and the year. I assign the values in variable "ddn" for
> further processing. Then I have an array that assigns french month to
> numeral month value like so :
>
> $smarty->assign('month_id',array(0,1,2,3,4,5,6,7,8,9,10,11,12));
> $smarty->assign('month_name',array('mois','janvier',
> 'février','mars','avril','mai','juin','juillet',
> 'août','septembre','octobre','novembre','décembre'));
>
> Maybe not the best option but it does the trick
>
> Reynier Perez Mira wrote:
>
> >Hi list:
> >
> >I'm working with Smarty component {html_select_date prefix="fecha"
> >time=$time start_year="1950" end_year="+1"}
> >
> >But this return date in english and I want it in spanish. When I put this
> >at first into my php file
> >
> >setlocale(LC_ALL, 'es_ES);
> >
> >nothing happend and things come in english. How can I solve this problem?
> >
> >It's posible with Smarty? Exists any plugin or addons that return things
> >in spanish format?
> >
> >Regards
> >
> >
> >
> >
> >
> >Reynier Pérez Mira
> >
> >3ero. Ing. Informática
> >
> >Entre más inteligente me siento, más me doy cuenta de lo ignorante que
> >soy.
> >
> >
> >
> >
> >
>
> --
> Smarty General Mailing List (http://smarty.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация