Rev 3 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3 | Rev 7 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | <?php |
1 | <?php |
2 | 2 | ||
3 | /* |
3 | /* |
4 | * PHP Counter mit Reloadsperre, Textdatenbank und Graphic-Libary (without Error Images) |
4 | * PHP Counter mit Reloadsperre, Textdatenbank und Graphic-Libary (without Error Images) |
5 | * (C)Copyright 2010 - 2019 Daniel Marschall |
5 | * (C)Copyright 2010 - 2022 Daniel Marschall |
6 | * Revision: 2019-02-18 |
6 | * Revision: 2022-01-09 |
7 | */ |
7 | */ |
8 | 8 | ||
9 | function pdox_execute($statement, $args=array()) { |
9 | function pdox_execute($statement, $args=array()) { |
10 | if (!$statement->execute($args)) { |
10 | if (!$statement->execute($args)) { |
11 | echo "SQL Error <br />"; |
11 | echo "SQL Error <br />"; |
Line 71... | Line 71... | ||
71 | $del_B = ( ( ( $var_Max - $var_B ) / 6 ) + ( $del_Max / 2 ) ) / $del_Max; |
71 | $del_B = ( ( ( $var_Max - $var_B ) / 6 ) + ( $del_Max / 2 ) ) / $del_Max; |
72 | 72 | ||
73 | if ($var_R == $var_Max) $h = $del_B - $del_G; |
73 | if ($var_R == $var_Max) $h = $del_B - $del_G; |
74 | else if ($var_G == $var_Max) $h = ( 1 / 3 ) + $del_R - $del_B; |
74 | else if ($var_G == $var_Max) $h = ( 1 / 3 ) + $del_R - $del_B; |
75 | else if ($var_B == $var_Max) $h = ( 2 / 3 ) + $del_G - $del_R; |
75 | else if ($var_B == $var_Max) $h = ( 2 / 3 ) + $del_G - $del_R; |
- | 76 | else $h = 0; // should not happen |
|
76 | 77 | ||
77 | if ($h < 0) $h++; |
78 | if ($h < 0) $h++; |
78 | if ($h > 1) $h--; |
79 | if ($h > 1) $h--; |
79 | } |
80 | } |
80 | 81 |