title: DB returns string instead of int (mysqlnd for PHP-7.1 / Laravel)
body: <p>A few days ago, <a href="https://stackoverflow.com/questions/42791557/php-laravel-type-of-var-is-different-from-local-to-server">I asked a question about a bug I found in Laravel</a>.</p>
  
  <p>To fix it, I installed php5-mysqlnd on my server.</p>
  
  <p>Today, I upgraded my application to the latest php 7.1.*. Everything works correctly, except the bug is back again, i.e. integers in the database are returned as strings, which fails my strict comparison.</p>
  
  <p>I tried to find a package for mysqlnd for php 7.1 but there are none (yet?). But mysqlnd seems enabled though...</p>
  
  <p><strong>phpinfo()</strong></p>
  
  <pre><code>PHP Version =&gt; 7.1.3-2+0~20170315222009.20+jessie~1.gbpc7e7dd
  System =&gt; Linux 3.16.0-4-amd64 #1 SMP Debian 3.16.36-1+deb8u2 (2016-10-19) x86_64
  
  mysqlnd
  mysqlnd =&gt; enabled
  Version =&gt; mysqlnd 5.0.12-dev - 20150407 - $Id: b396954eeb2d1d9ed7902b8bae237b287f21ad9e $
  
  pdo_mysql
  PDO Driver for MySQL =&gt; enabled
  Client API version =&gt; mysqlnd 5.0.12-dev - 20150407 - $Id: b396954eeb2d1d9ed7902b8bae237b287f21ad9e $
  </code></pre>
  
  <p>Output on localhost:</p>
  
  <blockquote>
    <p>"id" => 5</p>
  </blockquote>
  
  <p><strong>Output on server:</strong></p>
  
  <blockquote>
    <p>"id" => "5"</p>
  </blockquote>
  
  <p>1/ Is there something else I should look?</p>
  
  <p>2/ In general, should I refactor my code to accept strings from the db instead of expecting ints?</p>
  
  <p>Thank you.</p>