YouTube's API has an "onStateChange" event that can be used to trigger behavior when the video ends, like this:
<div id="player"/>
<script src="http://www.youtube.com/player_api"></script>
<script>
var player;
function onYouTubePlayerAPIReady() {
$('.submit_div').hide();
player = new YT.Player('player', {
height: '390',
width: '640',
videoId: 'Su2qIrTmv1c',
events: {
'onStateChange': onStateChange
}
});
}
function onStateChange(event) {
if (event.data == 0) {
$('.submit_div').show();
}
}
</script>