use same object for different files in php
<p>I have two files say file1.php and file2.php. I have one php file named form in which class form has been defined.
I have created an object in file1.php as follow:</p>

<pre><code>require_once('form.php');
$x=$_GET['field'];
$form = new Form("", ""); 
$personal = new Block("");

$address = new TextArea("address", $x, "", 3, 30); 
$personal-&gt;add($address);
$form-&gt;add($personal);
echo $form;
</code></pre>

<p>now i want to use this object $form and $personal in another file file2.php which is as follow:</p>

<pre><code>$personal = new Block("");
$name = new Text("name",$x);
$personal-&gt;add($name);
$form-&gt;add($personal);
echo $form;
</code></pre>

<p>how can i use these objects in php. please help.</p>
