title: Cross check if multiple variable are equal in php
body: <p>Is there any efficient way to check these multiple variable values with each other?<br>
  Example: If value of <code>$v1</code> is <b>abc</b> and value of <code>$v2</code> is <b>abc</b> and other variables are empty then return error because two values are same.<br>
  Another Example: If value of <code>$v1</code> is <b>abc</b> and value of <code>$v4</code> is <b>abc</b> and other variables are empty then return error because two values are same.<br>
  Like check every variable with every other variable, if it's same with anyone then return an error.</p>
  
  <pre><code>$v1 = $_POST['v1'];
  $v2 = $_POST['v2'];
  $v3 = $_POST['v3'];
  $v4 = $_POST['v4'];
  $v5 = $_POST['v5'];
  $v6 = $_POST['v6'];
  </code></pre>