title: PHP: process Excel cell with new line character
body: <p>I'm building Excel template to get data about products from our users. The problem is that there are certain fields number of which can vary. </p>
  
  <p>For example, product can have 1 contributor or 12 contributors. Each contributor have the following fields:</p>
  
  <ul>
  <li>key name</li>
  <li>name before key</li>
  <li>role</li>
  <li>biography</li>
  </ul>
  
  <p>I don't think is good idea to include 12 * 4  columns to Excel template, because on the next day user can send product which has 13 contributors.</p>
  
  <p>I decided that I will include data about all contributors in one cell, for example in cell "Contributor Key Name" I will have name of all product contributors, in cell "Contributor Role" I will have roles of all contributors etc.</p>
  
  <p>I wanted to divide contributors data by new line symbol. I created Excel table with the following data:</p>
  
  <p><img src="https://i.stack.imgur.com/aYLJ4.png" alt="enter image description here"></p>
  
  <p>The problem is that when I read value of these cells ("Contributor Key Name" for example) in PHP I don't see new line symbol. Instead I receive string with strange characters:</p>
  
  <p><img src="https://i.stack.imgur.com/ZJyE5.png" alt="enter image description here"></p>
  
  <p>I tried to do </p>
  
  <pre><code>explode('\n',$cellValue);
  </code></pre>
  
  <p>but it doesn't work.</p>
  
  <p>I use PHPExcel library for working with table.</p>
  
  <p>My question is - how new line symbol is encoded in Excel? What would you recommend to use as delimiter in Excel cells?</p>
  
  <p>UPD:</p>
  
  <p>So, in order to divide strings by new line character you should use "\n" as delimiter.</p>
  
  <p>I think, that strange symbols appeared in my string because initially I created table in Numbers app and then export to xslx format. (Numbers has some problem with new line character during export)</p>