title: Modify Elements Content In given URL using Simple PHP Parser
body: <p>Below is my code. PHP code</p>
  
  <pre><code>&lt;?php
  include('simple_html_dom.php');
  $id=$_GET['id'];//Some URL like index.php
  $dom = file_get_contents($id);
  $html = file_get_html($id);
  ?&gt;
  &lt;html lang="en" class="wide smoothscroll wow-animation"&gt;
  &lt;head&gt;
  &lt;meta http-equiv="Content-Type" content="text/html; charset=windows-1252"&gt;
  &lt;title&gt;Update Content&lt;/title&gt;
  &lt;meta name="description" content="" /&gt;
  &lt;meta name="keywords" content="" /&gt;
  &lt;meta name="format-detection" content="telephone=no"/&gt;
  &lt;meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/&gt;
  &lt;link rel="stylesheet" href="css/style.css"&gt;
  &lt;link rel="stylesheet" type="text/css" href="css/style1.css"&gt;
  &lt;link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"&gt;
  &lt;link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css"&gt;
  &lt;/head&gt;
  &lt;div class="container"&gt;
    &lt;form class="form-horizontal"&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="email"&gt;Page Name&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="page_name" value="&lt;?php echo $filename;?&gt;" disabled&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php 
  foreach($html-&gt;find('meta[name=keywords]') as $element) {
  ?&gt;    &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;Meta Keyword&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;textarea class="form-control" id="meta_keyword"&gt;&lt;?php echo $element-&gt;content; ?&gt;&lt;/textarea&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } 
      foreach($html-&gt;find('meta[name=description]') as $element) {
  ?&gt;  
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;Meta Description&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;textarea class="form-control" id="meta_description"&gt;&lt;?php echo $element-&gt;content; ?&gt;&lt;/textarea&gt;
        &lt;/div&gt;
      &lt;/div&gt;
       &lt;?php } foreach($html-&gt;find('title') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;Title&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="title" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h1') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H1&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h1" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h2') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H2&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h2" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h3') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H3&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h3" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h4') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H4&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h4" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h5') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H5&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h5" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } foreach($html-&gt;find('h6') as $element) {?&gt;
      &lt;div class="form-group"&gt;
        &lt;label class="control-label col-sm-2" for="pwd"&gt;H6&lt;/label&gt;
        &lt;div class="col-sm-10"&gt;
          &lt;input type="text" class="form-control" id="h6" value="&lt;?php echo $element-&gt;innertext; ?&gt;"&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;?php } ?&gt;
      &lt;br/&gt;&lt;br/&gt;
    &lt;div class="form-group"&gt; 
      &lt;div class="col-sm-offset-2 col-sm-10"&gt;
        &lt;button class="btn btn-lg btn-primary" id="content_submit" type="button" style="color:#fff"&gt;Submit&lt;/button&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  
    &lt;/form&gt;
  &lt;/div&gt;
  &lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"&gt;&lt;/script&gt;&lt;script src="js/jquery.form.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>Refrence I used for this <a href="http://simplehtmldom.sourceforge.net/" rel="nofollow">http://simplehtmldom.sourceforge.net/</a></p>
  
  <p>Here I can Get all HTML elements with that code.And I want to modify the Same HTML element with Updated Text.But I don't get any reference from anywhere.Please is my page screenshot.</p>
  
  <p><a href="https://i.stack.imgur.com/PzlFS.png" rel="nofollow"><img src="https://i.stack.imgur.com/PzlFS.png" alt="enter image description here"></a></p>
  
  <p>If I change something in that h3 textbox it will change in about.php <code>&lt;h3&gt;New text&lt;/h3&gt;</code> How can I do this If anyone knows the solution Please help me to get out of this problem.Thanks in advance.</p>