0; $i--)
if (abs((($i/$count_buff)-$price_buff)/$price_buff) < 0.001)
return $i."+".($count_buff - $i)." gratis";
}
return ((1-$price_buff)*100)."% korting per ".$count_buff."-pack";
}
?>
webshop
hier zijn de aanbiedingen
query("select product.id, product.name as name, promotion.count_buff, promotion.price_buff from promotion join product on product.id = promotion.product");
while ($product = $res->fetch_object()) {
echo "- id\">$product->name: ";
echo promobuff2str($product->price_buff, $product->count_buff);
echo "
";
}
?>