validate form php 4 inputs, one must be filled
<p>I have a form which I need to fill in one field. I am trying but not having any success. </p>

<p>Please point to me where I am doing it wrong.</p>

<pre><code>if($text1=='' &amp;&amp; $text2=='' &amp;&amp; ($text3!='' || $text4!='' || $text5!='' || $text6!='')){

                    $abc-&gt;redirect('../xxxx.php');  
                    exit;

                    }


&lt;tr&gt;
&lt;td&gt;title: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="dailyprice" name="text1" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;td&gt;Desc: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="weeklyprice" name="text2" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;Daily Price: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="dailyprice" name="text3" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;td&gt;Weekly Price: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="weeklyprice" name="text4" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Weekend Price: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="weekendprice" name="text5" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;td&gt;Monthly Price: $&lt;/td&gt;
&lt;td&gt;&lt;input type="text" id="monthlyprice" name="text6" style="height: 25px; border: 1px solid #888; width: 80px;"&gt;&lt;/td&gt;
&lt;/tr&gt;
</code></pre>

<p>Thanks</p>
