String.replace(/( | | )/gm," ")
<script type="text/javascript"> var get_banner_detail = `<?php echo json_encode($get_banner_detail); ?>`; exam = get_banner_detail.replaceAll(/( | | )/gm, '<br>'); </script>