| 123456789101112131415161718 |
- <?php require('auth-validate.php');
- //get all companies
- //get a company's data
- $stmt_file = $dbh->prepare(
- "SELECT id_company, name, description
- FROM company");
-
- $stmt_file->execute();
- $rows = $stmt_file->fetchAll(PDO::FETCH_ASSOC);
- echo json_encode($rows, JSON_PRETTY_PRINT);
- ?>
|