title: PHP Echo a number using else if and greater than or less than
body: <p>I have a script which is like a whois database. This function returns site views and I want to echo between value.</p>
  <p>How can I echo and return one result? If the number is say 4000, it should return only <strong>1k-10k</strong></p>
  <p>Rows are like</p>
  <blockquote>
  <p>1550330</p>
  <p>1000000</p>
  </blockquote>
  <p>The code:</p>
  <pre><code>$siteTotalViews=1000000;
  if($siteTotalViews &lt;= 100){
      echo '0-100';
  }
  if($siteTotalViews &lt;= 1000){
      echo '100-1k';
  }
  if($siteTotalViews &lt;= 10000){
      echo '1k-10k';
  }
  if($siteTotalViews &lt;= 100000){
      echo '10k-100k';
  }
  if($siteTotalViews &lt;= 1000000){
      echo '100k-1 mil';
  }
  if($siteTotalViews &lt;= 2000000){
      echo '1 mil-2 mil';
  }
  if($siteTotalViews &lt;= 5000000){
      echo '2 mil-5 mil';
  }
  if($siteTotalViews &lt;= 10000000){
      echo '5 mil-10 mil';
  }
  if($siteTotalViews &gt;= 10000000){
      echo '10 mil +';
  }
  </code></pre>