init_user_agent.php 258 B

12345678910111213
  1. <?php
  2. require(__DIR__ . '/../vendor/autoload.php');
  3. $jsonfile = __DIR__ . '/../Tests/user_agents.json';
  4. $uas = json_decode(file_get_contents($jsonfile), true);
  5. foreach( $uas as $key => &$val ) {
  6. $val = parse_user_agent($key);
  7. }
  8. echo json_encode($uas);