Tag: vbulletin

为什么vBulletin在js feed中返回一个函数?

如果你加载一个vBulletin(3.6.8)js feed例如http://www.example.com/forum/external.php?type=js,你会得到这样的输出: function thread(threadid, title, poster, threaddate, threadtime) { this.threadid = threadid; this.title = title; this.poster = poster; this.threaddate = threaddate; this.threadtime = threadtime; } var threads = new Array(15); threads[0] = new thread(370145, …rest of threads in an array…); 这个函数Object有什么用,如果eval()可能是不安全的,那么从javascript(Node.js)评估这个JS的安全方法是什么。 var phantom = require('phantom'); phantom.create(function(ph) { return ph.createPage(function(page) { return page.open("http://www.example.com/forum/external.php?type=js&forumids=1&lastpost=1", function(status) { console.log("opened […]