- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
$result_row = $db->query("SELECT DISTINCT good_vars.coef_value, good_vars.coef_type ... ");
$row = $db->fetch_array($result_row);
$coef_type = $row['coef_type'];
$coef_value = $row['coef_value'];
$array = explode(',', ($coef_type.','.$coef_value));
$result = 0;
if ($array[0] == 2) {
$result = $price * $array[1] / 100;
} elseif ($array[0] == 3) {
$result = $array[1];
}