Can anyone Plz help me in Javascript. I am trying to make a puzzle game in Javascript but it's not running. Here is the coding..
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>Puzzle Game</title><style type="text/css">img{position:absolute;}#owais{left:39px;top:44px;}#kalam{left:101px;top:44px;}</style><script type="text/javascript">function puzzle(){ if(document.getElementById('owais').style.left == parseInt(62 + document.getElementById('kalam').style.left)) { document.getElementById('owais').style.left = '101px'; document.getElementById('kalam').style.left = '39px'; }}</script></head><body><img src="Bair.jpg" width="61" height="60" alt="Bair1" id="owais" onclick="puzzle();"/><img src="Bair2.jpg" width="61" height="60" alt="Bair2" id="kalam"/></body></html>
Plz Help me about this coding..When i given this condition out of if it is running..