title: replace line in file with sed command
body: <p>I have this script:</p>
  
  <pre><code>#!/bin/sh
  local name="url"
  local line='{ "name": "url", "value": "http:\/\/www.example.com\/dir1\/page1" }'
  
  local name2="protocol"
  local line2='{ "name": "protocol", "value": "ftp" }'
  
  sed -i "/\&lt;$name2\&gt;/s/.*/$line2/" /mydir/myfile
  sed -i "/\&lt;$name\&gt;/s/.*/$line/" /mydir/myfile
  </code></pre>
  
  <p>myfile contain:</p>
  
  <pre><code>{ "name": "url", "value": "http:\/\/www.example.com\/dir2\/page2" }
  { "name": "url2", "value": "http:\/\/www.example.net/page" }
  { "name": "protocol", "value": "http" }
  </code></pre>
  
  <p>I detect a problem with <code>/</code> symbol in value field with my sed command. How to fix this error?</p>