Javascript 使用Node.js获取特定JSON数据

Javascript 使用Node.js获取特定JSON数据,javascript,json,node.js,mongodb,Javascript,Json,Node.js,Mongodb,我在MongoDB中存储了各种tweet的数据,并以JSON格式显示,如下所示。我只想从这个批量数据中获取位置名称,并使用node.js将其显示在另一个页面上 有谁能帮我做这件事吗?那将是一个很大的帮助 { "_id": "5524d1c72d02a4bce134cabd", "id": 585697991878639600, "created_at": "Wed Apr 08 06:57:37 +0000 2015", "id_str": "5856979918

我在MongoDB中存储了各种tweet的数据,并以JSON格式显示,如下所示。我只想从这个批量数据中获取位置名称,并使用node.js将其显示在另一个页面上

有谁能帮我做这件事吗?那将是一个很大的帮助

{
    "_id": "5524d1c72d02a4bce134cabd",
    "id": 585697991878639600,
    "created_at": "Wed Apr 08 06:57:37 +0000 2015",
    "id_str": "585697991878639618",
    "text": "Friends follow @ArtistAloud page join this contest and win cool fk voucher #AAMA2014 @Mika0562  
             @genver1 @BabuBeg @sunitakatyal @sweet_isha1",
    "source": "<a href=\"http://twitter.com\" rel=\"nofollow\">Twitter Web Client</a>",
    "truncated": false,
    "in_reply_to_status_id": null,
    "in_reply_to_status_id_str": null,
    "in_reply_to_user_id": null,
    "in_reply_to_user_id_str": null,
    "in_reply_to_screen_name": null,
    "user": {
      "id": 141550730,
      "id_str": "141550730",
      "name": "Anuradha Chhabra",
      "screen_name": "freeky9219",
      "location": "Mumbai",
      "url": null,
      "description": null,
      "protected": false,
      "verified": false,
      "followers_count": 1274,
      "friends_count": 1692,
      "listed_count": 11,
      "favourites_count": 24669,
      "statuses_count": 57491,
      "created_at": "Sat May 08 11:10:09 +0000 2010",
      "utc_offset": null,
      "time_zone": null,
      "geo_enabled": true,
      "lang": "en",   
 },
{
    "_id": "552b5f3081d03fdca14c0d74",
    "id": 587499514560405500,
    "created_at": "Mon Apr 13 06:16:14 +0000 2015",
    "id_str": "587499514560405504",
    "text": "RT @ErnestoRiley: Look, friends tease each other. It's how we show love.\nSo everyone just Chill..\nAnd be respectful with your comments ðŸŒ",
    "source": "<a href=\"http://twitter.com/download/iphone\" rel=\"nofollow\">Twitter for iPhone</a>",
    "truncated": false,
    "in_reply_to_status_id": null,
    "in_reply_to_status_id_str": null,
    "in_reply_to_user_id": null,
    "in_reply_to_user_id_str": null,
    "in_reply_to_screen_name": null,
    "user": {
      "id": 2239133156,
      "id_str": "2239133156",
      "name": "21.04.15《",
      "screen_name": "justlorina",
      "location": "Sophia & Katie â¤ï¸ ",
      "url": "http://Instagram.com/justlorina_",
      "description": "The Vampire Diaries is the Story of Elena falling in love with Damon -LJ. Smith • #PLL #TW addicted • I met Ian 17/18 May 2014 • [Books||Shows||Movies||Music]",
      "protected": false,
      "verified": false,
      "followers_count": 3440,
      "friends_count": 998,
      "listed_count": 21,
      "favourites_count": 17533,
      "statuses_count": 34057,
      "created_at": "Tue Dec 10 13:05:42 +0000 2013",
      "utc_offset": 7200,
      "time_zone": "Berlin",
      "geo_enabled": true,
      "lang": "en",
      "contributors_enabled": false,
      "is_translator": false,
    }
{
“_id”:“5524D1C72D02A4 BCE134CABD”,
“id”:585697991878639600,
“创建时间”:“Wed Apr 08 06:57:37+0000 2015”,
“id_str”:“585697991878639618”,
“文本”:“好友关注@ArtistAloud page加入本次比赛,赢取酷炫fk代金券”#AAMA2014@Mika0562
@genver1@BabuBeg@sunitakatyal@sweet_isha1“,
“来源”:“,
“截断”:false,
“在对状态id的回复中”:null,
“在对状态的回复中”id“str”:空,
“in_reply_to_user_id”:null,
“在对用户id的回复中”:null,
“回复至屏幕名称”为空,
“用户”:{
“id”:141550730,
“id_街”:“141550730”,
“名称”:“Anuradha Chhabra”,
“屏幕名称”:“freeky9219”,
“地点”:“孟买”,
“url”:空,
“描述”:空,
“受保护”:错误,
“已验证”:错误,
“粉丝数”:1274,
“朋友数”:1692,
“列出的计数”:11,
“最受欢迎人数”:24669,
“状态计数”:57491,
“创建时间”:“2010年5月8日星期六11:10:09+0000”,
“utc_偏移量”:空,
“时区”:空,
“geo_enabled”:正确,
“郎”:“恩”,
},
{
“_id”:“552b5f3081d03fdca14c0d74”,
“id”:587499514560405500,
“创建时间”:“2015年4月13日星期一06:16:14+0000”,
“id_街”:“587499514560405504”,
“文本”:“RT@ErnestoRiley:看,朋友们互相取笑。这就是我们表达爱的方式。\n所以每个人都要冷静…\n尊重你的评论”,
“来源”:“,
“截断”:false,
“在对状态id的回复中”:null,
“在对状态的回复中”id“str”:空,
“in_reply_to_user_id”:null,
“在对用户id的回复中”:null,
“回复至屏幕名称”为空,
“用户”:{
“id”:2239133156,
“id_街”:“2239133156”,
“名称”:“2015年4月21日”,
“屏幕名称”:“justlorina”,
“地点”:“索菲亚和凯蒂”,
“url”:”http://Instagram.com/justlorina_",
“描述”:“吸血鬼日记是关于埃琳娜爱上达蒙的故事——LJ.史密斯——上瘾——我在2014年5月17日18日遇到了伊恩——书籍、表演、电影、音乐”,
“受保护”:错误,
“已验证”:错误,
“粉丝数”:3440,
“朋友数”:998,
“列出的计数”:21,
“最受欢迎人数”:17533,
“状态计数”:34057,
“创建时间”:“2013年12月10日星期二13:05:42+0000”,
“utc_偏移量”:7200,
“时区”:“柏林”,
“geo_enabled”:正确,
“郎”:“恩”,
“已启用贡献者”:false,
“is_translator”:错误,
}

我建议您在谷歌上搜索mean.js和mean.io,这两个版本都为基于Mongo和Node的应用程序提供了一个很好的起点(带有Express和Angular,因此是mean),同时还有一些额外的好处