I have a few additions to this.First of all, you don't need the variable x.You could just do this:
y=document.getElementByID("name").heightif(y>23){//do something}
But even so, you might mave an other problem. The y variable may not contain the objects height value as an integer, but rather a string with "px" added to it (like "200px", for example).If you get that problem, you can fix it like this:
x=y.slice(0,y.length-2);
This will shave the last two characters off the string, and ad the rest to the variable x (like "200", for example).Even so, you might still get the problem that x is treated as a string, and not an integer. If you get that, you can fix it like this:
x=eval( y.slice(0,y.length-2) );
What eval() does is execute a string as code, so if the value of y.slice(0,y.length-2) is the string "200", it will output 200, like you had written it into the code by hand.Good luck with it!