最も簡単な方法は、その例の JavaScript をコピーして、独自の .js ファイルに入れることです。
HTML から mootools ライブラリ スクリプトを呼び出す<script src="http://ajax.googleapis.com/ajax/libs/mootools/1.2.4/mootools-yui-compressed.js"></script>
次に、プラグインファイルを呼び出します<script src="js/plugin.js"></script>
次に、初期化スクリプトを含めます(その例から、ページの下部にあるように見えますが、よくわかりません)
<script type="text/javascript" charset="utf-8">
//<![CDATA[
window.addEvent('domready', function(){
var total = $('total'); // this is the id of the element that will display the number
var totalFx = new Fx.CashRegister(total, {duration: 2000});
totalFx.start(124353526.99); // this is the number that you want to show first when page loads
});
</script>
私が編集したこのjsBinを参照してください