JwPlayer :: Exact postition with getPosition()

HI

I was able to get the position of the video by using the jwplayer().getPosition() function but I get something like 171.97 but the timer on the video showed me 2:51. How can I exactly get the position as 2:51 instead of 171.97?

Screenshot: http://i.imgur.com/NzMxk.png

My Code:


<script type="text/javascript">
		jwplayer("mediaplayer").setup({
			flashplayer: "player.swf",
			file: "mane.mp4",
			image: "preview.jpg",
                        events: {
                         onPlay: function(event) {
                            timeMsg();
                         }
                        }
		});


                function timeMsg()
                {
                    var t=setTimeout("alertMsg()",100);
                }
                function alertMsg()
                {
                    var timeline =  ( jwplayer().getPosition());
                    $('#position').text(timeline);
                    timeMsg();
                }

	</script>
	

Any help is appreciated.

Hi

it is showing you right answer
jwplayer calculate position in seconds
2:51… will be 120sec+51sec=171sec
171.97 sec is exactly right

hope that helps
for more information on jwplayer api check the link below

http://www.longtailvideo.com/support/jw-player/28851/javascript-api-reference/