Example #1
0
                                <td><button id="btnFind" onclick="submit()" >Find</button></td>
                            </tr>
                        </table>
                    <?php 
}
?>
                    <br/>
                    <table border="1" cellspacing="0" width="550" align="center" class="ui-corner-all">
                        <tr class="ui-widget-header">
                            <th style="width: 300px">Item</th>
                            <th style="width: 100px">Loss</th>
                        </tr>
                        <?php 
include_once "../model/Item.php";
$itemObj = new Item();
$items = $itemObj->getLoss($_POST['txtDate1'], $_POST['txtDate2']);
foreach ($items as $item) {
    if ($item["loss"] != 0) {
        ?>
                            <tr>
                                <td>
                                    <?php 
        echo $item["name"];
        ?>
                                </td>
                                <td align="right">
                                    <?php 
        echo $item["loss"];
        ?>
                                </td>
                            </tr>