how to get division result only int part in php code example Example: integer division in php $a = 5; $b = 2; echo intdiv($a, $b); // 2