'That quote no longer exists.'])); } $client_id = intval($doc['client_id']); enforceClientAccess(); $doc_number = billingNumber($doc_type, $doc); $lines = count(billingItems('quote', intval($doc['quote_id']))); $clients = []; $sql = mysqli_query($mysqli, "SELECT client_id, client_name, client_abbreviation FROM clients WHERE client_archived_at IS NULL " . clientScopeSql('clients.client_id') . " ORDER BY client_name ASC"); while ($row = mysqli_fetch_assoc($sql)) { $clients[] = $row; } ob_start(); ?>