title: Change JSON value with PHP script
body: <p>I have a JSON <a href="http://pastebin.com/index/LwAhi59r" rel="nofollow noreferrer">http://pastebin.com/index/LwAhi59r</a></p>
  <p>And I have a PHP script in which I want to change my JSON value of each domain and template from each site. I would like to know what would be a good PHP code to change the values with an input and a selector in which you can choose which site you want to change it from. I got this php code I think it a good start but I don't know how to proceed.</p>
  <pre class="lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
      &lt;title&gt;&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;h2&gt;Domain of Template veranderen met PHP script&lt;/h2&gt;
      &lt;form action=&quot;process.php&quot; id=&quot;form&quot; method=&quot;post&quot;&gt;
            &lt;select name=&quot;selector&quot;&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;cms18.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;dmmd.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;opmaat.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;opmaatdebiteurenadvies.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;navbar.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;test18.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;huisartsplus.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;robertenrademaker.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;tilburg.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;cbk-groningen.test.silverbee.nl&lt;/option&gt;
          &lt;option value=&quot;cms18.test.silverbee.nl&quot;&gt;getbusyinc.test.silverbee.nl&lt;/option&gt;
      &lt;/select&gt;
             Value:&lt;input type=&quot;text&quot; name=&quot;value&quot;&gt;
            
            &lt;input type=&quot;submit&quot; value=&quot;Send&quot;&gt;
      &lt;/form&gt;
  &lt;br&gt;
   
  &lt;?php 
      $select = $_POST['selector'];
      //neem de json bestand array in php
      $lijst= file_get_contents('list.json');
      /*echo $lijst;*/
   
      //neem de lijst json en decodeerd het json string. als true maakt hij er een array van.
      $decoderen= json_decode($lijst, true);
      /*echo $decoderen;*/
      echo &quot;&lt;ul&gt;&quot;;
          foreach ($decoderen as $key =&gt; $value) 
              {
                  echo &quot;&lt;li&gt;&quot;.$key.&quot;&lt;ul&gt;&quot;;
                  foreach ($value as $key1 =&gt; $value1) 
                  {
                      echo &quot;&lt;li&gt;&quot;.$key1.&quot;: &quot;.$value1.&quot;&lt;/li&gt;&quot;;
                  }
                  echo &quot;&lt;/ul&gt;&quot;.&quot;&lt;/li&gt;&quot;;
              }
      echo &quot;&lt;/ul&gt;&quot;;
  /*------------------------------------------------------------------------------------------------------*/
      /*foreach ($decoderen as $key =&gt; $value) {
      if((string)$key-&gt; == $this-&gt;put('')) {
          $value-&gt;name=&quot;--&quot;;(string)$value-&gt;description=&quot;--&quot;;
      }*/ This is the last code i was trying to use i found this in another site someone had same problem but i couldnt come out with this. BTW i am new in PHP.
          
  ?&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>