答案 0 :(得分:2)
使用replace()
var tempStr = $('.nav-modal-main').text();
tempStr.replace(/"/g, '').replace(/,/g,'').trim();
$(document).ready(function(){
var tempStr = $('.nav-modal-main').text();
$('.nav-modal-main').text(tempStr.replace(/"/g, '').replace(/,/g,'').trim());
});

<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div class="nav-modal-main">
", "
Testing
</div>
&#13;
答案 1 :(得分:0)