<?php
function filter_wp_caption_text( $content ) {
return preg_replace(
'/<p[^>]+class="wp-caption-text"[^>]*>(.+)(?=<\/p>)/s',
'<div class="wp-caption-text">\1</div>',
$content
);
}
add_filter( 'the_content', 'filter_wp_caption_text', 12 );