摘要: 如果在一个容器中的子元素使用了position:absolute, 那么他可能会跑出父元素的框架范围。 如果想限定子元素在付元素的框架范围,可以在父元素上加position:relative; 对于一个父元素,比如bigWrapper, mainHeader, mainFooter 可以加上posi 阅读全文
posted @ 2014-08-08 15:25 Zhentiw 阅读(188) 评论(0) 推荐(0)
摘要: <!DOCTYPE html> <html> <head> <link rel="stylesheet" href="index.css" /> </head> <div class="db group"> <!-- 在含有float的容器中家group class--> <div id="l" s 阅读全文
posted @ 2014-08-08 03:34 Zhentiw 阅读(285) 评论(0) 推荐(0)
摘要: var vehicle1 = {type: "Motorboat", capacity: 6, storedAt: "Ammunition Depot"}; var vehicle2 = {type: "Jet Ski", capacity: 1, storedAt: "Reef Dock"}; v 阅读全文
posted @ 2014-08-08 00:31 Zhentiw 阅读(237) 评论(0) 推荐(0)
摘要: // Get /appointments{ "per_page": 10, "page": 1, "total": 50, "appointments": [ { "title": "Ms. Kitty Hairball Treatment", "cankelled": false, "identi 阅读全文
posted @ 2014-08-07 18:56 Zhentiw 阅读(262) 评论(0) 推荐(0)
摘要: The good Dr. recently had another team implement the server and they slightly messed up the format of the JSON returned for Appointment data. Instead 阅读全文
posted @ 2014-08-07 16:38 Zhentiw 阅读(199) 评论(0) 推荐(0)
摘要: 1. Ceate a route Class var AppRouter = Backbone.Router.extend({ }); 2. Add a route name it "show", listene to 'appointments/:id' var AppRouter = Backb 阅读全文
posted @ 2014-08-07 14:04 Zhentiw 阅读(191) 评论(0) 推荐(0)
摘要: First, memory is set aside for all necessary variables and declared functions. Function expression never got hosited in Javascirpt. Therefore, you can 阅读全文
posted @ 2014-08-05 16:21 Zhentiw 阅读(295) 评论(0) 推荐(0)
摘要: They’ve got a problem with their existing code, which tries to use a closure. Check it out: function assignLaser( shark, sharkList ){ var stationAssig 阅读全文
posted @ 2014-08-04 20:57 Zhentiw 阅读(241) 评论(0) 推荐(0)
摘要: function buildCoveTicketMarker(transport){ var passengerNumber = 0; return function(name){ passengerNumber++; alert("Ticket via the " +transport+ "Wel 阅读全文
posted @ 2014-08-04 20:15 Zhentiw 阅读(153) 评论(0) 推荐(0)
摘要: Returning a function from a function, complete with variables from an external scope, is called a closure. The entire contents of one of these inner f 阅读全文
posted @ 2014-08-04 18:33 Zhentiw 阅读(474) 评论(0) 推荐(0)