Esempio n. 1
0
if (isset($_GET["confirmation"])) {
    $confirmation = $_GET["confirmation"];
}
?>

<form method = "GET" action = "classify.php">
    Is weed page?<input type="submit" name="confirmation" value="yes" /><br/>
    Is weed page?<input type="submit" name="confirmation" value="no" />
    <input type="hidden" name="order" value ="<?php 
echo $order;
?>
"/>
</form><br/>

<?php 
$RawHTMLDB = new RawHTMLDB();
//Provide config setting
echo "before";
$RawHTMLDB->SetConfig($default_hostname, $default_username, $default_password, $default_db);
echo "after";
if ($confirmation == "null") {
    $result = $RawHTMLDB->getOrder($order);
    echo sizeof($result);
    if (sizeof($result) == 1) {
        $result = $result[0];
        echo "Link = " . $result["url"] . "<br/>";
        echo "Location = " . $result["country"] . ", " . $result["state"] . ", " . $result["city"] . "<br/>";
        echo "Positive = " . $result["positive"] . "<br/>";
        echo "Predict1 = " . $result["predict1"] . "<br/>";
        echo "Predict2 = " . $result["predict2"] . "<br/>";
        echo "Quantities = " . $result["alt_quantities"] . "<br/>";
Esempio n. 2
0
?>

<form method = "POST" action = "price.php">
    Quantity:<input type="text" name="quantity" value="" /><br/>
    Unit:<input type="text" name="unit" value="" /><br/>
    Price:<input type="text" name="price" value="" /><br/>
    <input type="hidden" name="order" value ="<?php 
echo $order;
?>
"/><br/>
    <input type="submit" value="Submit"/>
</form><br/>

<?php 
echo "<a href='/price.php?order=" . ($order + 1) . "'>Next</a><br/>";
$RawHTMLDB = new RawHTMLDB();
$PricesDB = new PricesDB();
//Provide config setting
$PricesDB->SetConfig($default_hostname, $default_username, $default_password, $default_db);
$RawHTMLDB->SetConfig($default_hostname, $default_username, $default_password, $default_db);
$result = $RawHTMLDB->getAltPricesQuantitiesOrder($order);
if (sizeof($result) == 1) {
    $result = $result[0];
    echo "Link = " . $result["url"] . "<br/>";
    echo "Location = " . $result["country"] . ", " . $result["state"] . ", " . $result["city"] . "<br/>";
    echo "Positive = " . $result["positive"] . "<br/>";
    echo "Predict1 = " . $result["predict1"] . "<br/>";
    echo "Predict2 = " . $result["predict2"] . "<br/>";
    echo "Quantities = " . $result["alt_quantities"] . "<br/>";
    echo "Prices = " . $result["alt_prices"] . "<br/>";
    echo $result["html"];