如何在asp.net嵌套数组中定义数组?

时间:2017-03-21 13:08:54

标签: c# asp.net arrays

在php中使用

$_array=array(
             1=>array("id"=>1,"name"=>"abc"),
             2=>array("id"=>2,"name"=>"vbn")

);
echo $_array[1]["id"];

如何使用asp.net c#?

1 个答案:

答案 0 :(得分:0)

在c#中你应该这样做:

var date = new Date("Tue, 21 Mar 2017 15:49:25 +0300");
    var day = date.getDay();
    var dom = date.getDate();
    var month = date.getMonth();
    var year = date.getYear();
    alert(day + " " + dom + " " + month + " " + parseInt(year+1900));