0

I really don't understand Javascript.

In PHP, I can remove quotes like this:

$tags_array = preg_replace('/"/', '', $tags_array);

How do I write it in Javascript?

Jonathan Leffler
  • 730,956
  • 141
  • 904
  • 1,278
ajsie
  • 77,632
  • 106
  • 276
  • 381
  • Do you mean "remove quote from an array of string"? You'll have to loop through the array to do it. – o.k.w Dec 22 '09 at 06:40

2 Answers2

6
str = str.replace(/"/g, '');
Annie
  • 6,621
  • 22
  • 27
1

You can do almost the same thing with javascript what you do with php, i mean many functions, here is the solution:

PHPJS

Sarfraz
  • 377,238
  • 77
  • 533
  • 578