title: Pass variable to another page using AJAX
body: <p>## <strong>This My test.php file</strong> ##</p>
  
  <pre><code> //here I am getting the variable value
  
  &lt;?PHP
   $name = $_POST('variable');
   echo $name;
  ?&gt;
  </code></pre>
  
  <p>## <strong>This my script</strong> ##</p>
  
  <pre><code> //avariable value passing to test .php file
  
  &lt;script type ="text/javascript"&gt;
    var name = "jani";
    $.ajax({
            type: 'POST',
            url: 'test/test.php',
            data: {'variable': name},
            });
  &lt;/script&gt;
  </code></pre>
  
  <p>###** I am getting this error  **###</p>
  
  <pre><code> Fatal error: Function name must be a string in 
                   D:\xampp\htdocs\test\test.php on line 2
  </code></pre>