On Fri, 01 Oct 2004 10:30:19 +0200, Marek Kilimajer <[EMAIL PROTECTED]> wrote:
> What about dumping the $month_names array and using strftime()?
Interesting -- more portable since the month names would then follow
locale settings.
Plus it paves the way for a really hairy one-liner. With apologies
Well, looks like the idea is alway the same, with some (very usefull)
variations.
Thanks for help!
Afan
> [EMAIL PROTECTED] wrote:
>> Hi,
>> to create a list of all months in drop-down menu I use this code:
>>
>> > $month_names = array(1=>'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul',
>> 'Au
[EMAIL PROTECTED] wrote:
Hi,
to create a list of all months in drop-down menu I use this code:
'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul',
'Aug', 'Sep', 'Oct', 'Nov', 'Dec');
?>
$i ";
}
?>
What about dumping the $month_names array and using strftime()?
--
PHP General Mailing List (http://w
Hi,
Friday, October 1, 2004, 6:16:46 AM, you wrote:
aan> Hi,
aan> to create a list of all months in drop-down menu I use this code:
aan> $month_names = array(1=>'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul',
aan> 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');
?>>
aan>
aan>
aan> for($i=1; $i<=12; $i++
On Thu, 30 Sep 2004 22:16:46 +0200 (CEST), [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hi,
> to create a list of all months in drop-down menu I use this code:
>
> $month_names = array(1=>'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul',
> 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');
> ?>
>
>
>
> for
What you have is basically what I do, but the current month check could be
tidied up and display the month name seeing as you have the array:
$selected_QuoteMonth = (date('m')==$i)?'SELECTED':'';
echo " $month_names[$i] ";
** CODE IS UNTESTED **
I'm sure if there is a better way then someone h
You can do it:
"
for ($i=1;$i<13;$i++)
{
echo "$month[$i]";
}
echo
--- [EMAIL PROTECTED] wrote:
> Hi,
> to create a list of all months in drop-down menu I
> use this code:
>
> $month_names = array(1=>'Jan', 'Feb', 'Mar', 'Apr',
> 'May', 'Jun', 'Jul',
> 'Aug', 'Sep', 'Oct', 'Nov', 'Dec')
7 matches
Mail list logo