title: JSON-LD and quotes in the content
body: <p>I have an issue with validating JSON-LD code by Google Structured Data Testing Tool. My article text is taken from MySQL database and put into JSON-LD structure by php script along the following lines:</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;script type="application/ld+json"&gt;
  {
      "@context": "http://schema.org",
      "@type": "Article",
      ...
      "articleBody": "&lt;?php echo article content here ?&gt;",
      ...
  }
  </code></pre>
  
  <p>The problem is that if the article text contains quotation marks (") then they conflict with JSON-LD block syntax and cause validation error. Basically the very first instance of (") in the article content indicates the end of articleBody and the next (") causes syntax error.</p>
  
  <p>The only idea I have is to pre-process article content with php and remove (") symbols. This works fine, but looks artificial:</p>
  
  <pre class="lang-json prettyprint-override"><code>    "articleBody": "&lt;?php echo str_replace( '"', '', article content here) ?&gt;",
  </code></pre>
  
  <p>Are there any standard workarounds available?</p>