IAmTrying,
примеры ваших строк?
<!DOCTYPE html>
<html>
<head>
<title>Untitled</title>
<meta charset="utf-8">
<style type="text/css">
</style>
</head>
<body>
<script>
function replaceBrackets(text){
return text.replace(/(^|\s|\')\'([^']+?)\'/g, '$1\"$2\"');
};
document.write(replaceBrackets("'vxcvc 123 vcxv' 'sdasvsdfsdfdasd' 'dsdasdas', 'pizza!' 'dsdfsdfsdsds' aren't 'you', 'b' 'you'.?, 'df'. 'dfg' 'dgfe' 'dfgvc' 'vcxsdf' "));
</script>
</body>
</html>