Created
April 9, 2015 13:06
-
-
Save LinZap/f7af3c5ccb41d25fcb04 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EJS 中: <div ejs="@bulid_urlitem"> </div> | |
// tar 會從外部傳 該 tag 近來 | |
function bulid_urlitem(tar){ | |
var cid = tar.attr('cid'); | |
api({did:4,cid:cid,limitnum:9},function(data){ | |
render({ | |
ejs:'views/urlitem', | |
data:data, | |
//這裡直接告訴 ejs 把畫面放進這個 div | |
target:tar | |
}); | |
}); | |
} | |
// 該 function 會自動幫你 run |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
At app.js