开发者

Sciptaculous number spinner

does anybody know of the existence of a number spinner component compatible with prototype/scriptaculous? Something like jQuery's spinner.

I'm looking for nothing fancy, just numbers开发者_JAVA百科.


A quick example:

HMTL

<input id="spinner" type="text" value="0" readonly="readonly">
<div id="up">▲</div>
<div id="down">▼</div>

Prototype 1.6

$('up').observe('click', function() { $('spinner').value++; });
$('down').observe('click', function() { $('spinner').value--; });​

Detailed version here (with CSS already).

PS: only tested on firefox and chrome

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜