title: How to add newlines or carriage returns to description on facebook graph API
body: <p>It sounds like a pretty simple question but I can find the answer no where. </p>
  
  <p>I have a post from a textarea. and I want to use the current facebook php library to do the following... </p>
  
  <pre><code>$description = $_POST['textarea_description'];
  
  //magic happens
  
  $attachment =  array(
  'access_token' =&gt; $token,
  'message' =&gt; "$title",
  'picture' =&gt; "$image_url",
  'link' =&gt; "$action_link",
  'name' =&gt; "$action_label",
  'caption' =&gt; "$caption",
  'actions' =&gt; $action_json,
  'description' =&gt; "$description",
   );
  
  $facebook-&gt;api('/'.$my_uid.'/feed', 'POST', $attachment);
  </code></pre>
  
  <p>and have it work. Right now it seems to ignore </p>
  
  <pre><code>&lt;br&gt; &lt;br /&gt; \n \r \n\r \r\n
  </code></pre>
  
  <p>but I am sure I might have done something to screw up my testing.. I just need to replace 'magic happens' with something that works. Right now it just converts all of the newlines I am throwing at it to spaces.. Pretty frustrating. Someone on the facebook forums suggested addslashed() of all things... but that did not seem to work for me</p>
  
  <p>Thanks,
  -FT</p>