i have captured a few clips on my computer and want to upload them on my website but i am facing a problem

my files are in mpg format. once i play them on window media player the timeline arrives to the end before the clips ends but i still can see the video with the sound till the end of the clip.

i am trying to convert these to a smaller mpg size, i have tryed multiple programs but each time the conversion is finished and i test the clip it stops before the end of the clip (at the same time where the timeline stops in media player)

any help resolving this problem please?