PHP Classes

File: input.test.php

Recommend this page to a friend!
  Packages of Max Base   PHP Auto Style Fixer   input.test.php   Download  
File: input.test.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Auto Style Fixer
Beautify PHP source code fixing its style
Author: By
Last change:
Date: 9 months ago
Size: 389 bytes
 

Contents

Class file image Download
<?php
function checkifhoused($productname, $supplier)
{
   
$db = mysqli_connect(DB_SERVER, DB_USER, DB_PASS, DB_NAME);
   
$sql = "SELECT * FROM " . TBL_PRODUCTS;
   
$result = mysqli_query($db, $sql);
    while (
$row = $result->fetch_assoc()) {
        if (
$row['supplierid'] == $supplier and $row['name'] == $productname) {
            return
true;
        }
    }
    return
false;
}