Пример #1
0
function calculateBalance($income, $expenditure)
{
    return convertDecimalPoint((double) $income - (double) $expenditure) + 0;
}
Пример #2
0
<?php

include 'includes/db_inc.php';
include 'includes/formatFunctions_inc.php';
require 'lib/FPDF/fpdf.php';
$query = 'SELECT * FROM product WHERE id=:id';
$stmt = $db->prepare($query);
$stmt->execute(['id' => $_GET['id']]);
$result = $stmt->fetch();
$pdf = new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial', 'B', 16);
$pdf->Cell(100, 10, 'Project Shopping', 1, 1);
$pdf->SetFont('Arial', 'B', 14);
$pdf->Cell(100, 10, 'Productdetails van: ' . $result['name']);
$pdf->Image('productImages/' . $result['image'], 10, 30, 35);
$pdf->Ln(50);
$pdf->SetFont('Arial', '', 12);
$pdf->Cell(100, 10, 'Beschrijving');
$pdf->Ln();
$pdf->SetFont('Arial', '', 10);
$pdf->MultiCell(0, 5, $result['description']);
$pdf->Ln(10);
$pdf->Cell(100, 10, 'Prijs');
$pdf->Ln();
$pdf->Cell(100, 10, convertDecimalPoint($result['price']) . ' euro');
$pdf->Output();
Пример #3
0
    <div class="row">
        <div class="col-md-12">
            <h3>Prijs</h3>
            <td><?php 
print convertDecimalPoint($result['price']);
?>
</td>
        </div>
    </div>

    <div class="row">
        <div class="col-md-12">
            <h3>Prijs</h3>
            <td><?php 
print convertDecimalPoint($result['price']);
?>
</td>
        </div>
    </div>

    <div class="row">
        <div class="col-md-12">
            <p>
                <a href="index.php">
                    <button class="btn btn-default">Terug naar de hoofdpagina</button>
                </a>
            </p>
        </div>
    </div>
Пример #4
0
        if (isset($row['image']) && !empty($row['image'])) {
            ?>
                    <img src="../productImages/<?php 
            print $row['image'];
            ?>
" alt="" width="100">
                <?php 
        }
        ?>
            </td>
            <td class="rowCategory"><?php 
        print $row['category'];
        ?>
</td>
            <td class="rowPrice"><?php 
        print convertDecimalPoint($row['price']);
        ?>
</td>
            <td>
                <a href="updateProduct.php?id=<?php 
        print $row['id'];
        ?>
" class="btn btn-success">Aanpassen</a>
            </td>
            <td class="delete" id="<?php 
        print $row['id'];
        ?>
">
                <input id="<?php 
        print $row['id'];
        ?>