parseInt() error: invalid argument
<p>I get a javascript error "invalid arguement" when I use parseInt(). What am i doing wrong?</p>

<p>The function is to increase the font size of every element on a frame by 1</p>

<pre><code>&lt;script&gt;
   var sizeCounter = 1;
    function changeFontSize(){
        //var elements = parent.main.document.getElementsByTagName
        var myElements = parent.main.document.getElementsByTagName('*')

        for (i=0;i&lt;myElements.length;i++){
                if(myElements[i].style.fontSize != null){       
                        var elmFontSize = myElements[i].style.fontSize + "";
                        elmFontSize.replace("px","");

                        if(elmFontSize != "") {
                            var elmFontSizeNum = parseInt(elmFontSize);

                        }
                            var resultSize = elmFontSizeNum + sizeCounter;

                            myElements[i].style.fontSize = resultSize + "px";


                        //alert(myElements[i].className)
                    }
                    sizeCounter++;
            }
    }


&lt;/script&gt;
</code></pre>
