私は何か間違ったことをしているかもしれないことを知っています。なぜ私がオブジェクトとしてトップになっているのか、誰か指摘してもらえますか??
$(document).ready(function(){
topwithpx='0px';
alert(topwithpx);
topstr=topwithpx.substr(0,topwithpx.length-2);
alert(topstr);
top=parseInt(topstr);
alert(top);
});
ありがとうございました: 'top' は予約済みのキーワード (Window.top) です。私の悪い。一次回答受付中。迅速な回答のためにすべてに+1。