日期:2011/11/28 来源:GBin1.com

偶然发现一个非常不错的生成在线测试的jQuery插件 - jQuizzy,这个插件能够帮助你快速的生成一个非常漂亮的在线测试应用。
主要特性:
倒入类库及其问题js:
HTML中调用如下JS:
init.js内容如下:
var init = {
'questions': [
{
'question': 'jQuery is a...',
'answers': ['JavaScript. library','Ruby Gem','PHP Framework','None of the above'],
'correctAnswer': 1
},
{
'question': 'jQuery uses CSS selectors and XPath expressions to select elements?',
'answers': ['false','true'],
'correctAnswer': 2
},
{
'question': 'What scripting language is jQuery written in?',
'answers': ['C','C#','javascript','java'],
'correctAnswer': 3
}
],
'resultComments' :
{
perfect: 'Albus, is that you?',
excellent: 'Outstanding, noble sir!',
good: 'Exceeds expectations!',
average: 'Acceptable. For a muggle.',
bad: 'Well, that was poor.',
poor: 'Dreadful!',
worst: 'For shame, troll!'
}
};
搞定!非常简单,你自己可以设计自己的风格!
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/8288/viewspace-712331/ ,如需转载,请注明出处,否则将追究法律责任。