Mal wider PHP Datei Problem?


Shorty1968

Erfahrenes Mitglied
#1
Hallo,
ich habe Folgenden Code der verursacht eine Weisse Seite und ich finde den Fehler nicht.
PHP:
// BOF lolly - addded Bonuspunkte Erweiterung
        if ((USE_POINTS_SYSTEM == 'true') && (DISPLAY_POINTS_INFO == 'true')) { // check that the points system is enabled
              $products_price_points = xtc_display_points($products_price[plain], xtc_get_tax_rate($product->data['products_tax_class_id']));
              $products_points = xtc_calc_products_price_points($products_price_points);
              $products_points_value = xtc_calc_price_pvalue($products_points);
            if (USE_POINTS_FOR_SPECIALS == 'true' || !$xtPrice->xtcCheckSpecial($product->data['products_id'])){
                $info_smarty->assign('PRODUCTS_POINTS', $products_points);
                $info_smarty->assign('PRODUCTS_POINTS_VALUE', $xtPrice->xtcFormat($products_points_value,'true'));
            } else {
                $info_smarty->assign('PRODUCTS_POINTS', TEXT_PRODUCT_NO_POINTS);
               }// else do not show points_value
        }
  // EOF lolly - addded Bonuspunkte Erweiterung
Ich habe Folgendes in die PHP Datei eingetragen,aber es kommt denoch keine Fehler ausgabe.
PHP:
error_reporting(E_ALL);
ini_set('display_errors', true);
[/code)
 
#2
Hast du mal geprüft ob er in die entsprechende IF Abfrage oder Else-Zweig rein geht?
PHP:
<?php
if ((USE_POITS_SYSTEM == 'true') && (DISPLAY_POINTS_INFO == 'true')) { // check that the points system is enabled
        echo 'USE_POITS_SYSTEM';
              $products_price_points = xtc_display_points($products_price[plain], xtc_get_tax_rate($product->data['products_tax_class_id']));
              $products_points = xtc_calc_products_price_points($products_price_points);
              $products_points_value = xtc_calc_price_pvalue($products_points);
            if (USE_POINTS_FOR_SPECIALS == 'true' || !$xtPrice->xtcCheckSpecial($product->data['products_id'])){
                echo 'USE_POINTS_FOR_SPECIALS';
                $info_smarty->assign('PRODUCTS_POINTS', $products_points);
                $info_smarty->assign('PRODUCTS_POINTS_VALUE', $xtPrice->xtcFormat($products_points_value,'true'));
            } else {
                echo 'NOT USE_POINTS_FOR_SPECIALS';
                $info_smarty->assign('PRODUCTS_POINTS', TEXT_PRODUCT_NO_POINTS);
               }// else do not show points_value
        } else {
    echo 'NOT USE_POITS_SYSTEM';
}
?>
Durchaus könnte es aber daran liegen:
PHP:
<?php
// statt: if ((USE_POITS_SYSTEM == 'true') && (DISPLAY_POINTS_INFO == 'true'))
if ((USE_POINTS_SYSTEM == 'true') && (DISPLAY_POINTS_INFO == 'true'))
?>
 

Shorty1968

Erfahrenes Mitglied
#3
Ich habe nun über umwegen herraus bekommen das es an folgendem liegt.
PHP:
$products_price_points = xtc_display_points($products_price[plain], xtc_get_tax_rate($product->data['products_tax_class_id']));
Die letzten zeilen ind er error.log sehen so aus.
Code:
[Sat Dec 22 16:57:32.927647 2018] [fcgid:warn] [pid 24975] [client 93.235.82.78:38548] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:57:46.719141 2018] [fcgid:warn] [pid 15864] [client 93.235.82.78:38599] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:57:52.536825 2018] [fcgid:warn] [pid 33970] [client 93.235.82.78:38642] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:58:26.362861 2018] [fcgid:warn] [pid 59733] [client 93.235.82.78:38792] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:58:34.871927 2018] [fcgid:warn] [pid 17641] [client 93.235.82.78:38809] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
 

ComFreek

Mod | @comfreek
Moderator
#7
Ich habe nun über umwegen herraus bekommen das es an folgendem liegt.
PHP:
$products_price_points = xtc_display_points($products_price[plain], xtc_get_tax_rate($product->data['products_tax_class_id']));
Die letzten zeilen ind er error.log sehen so aus.
Code:
[Sat Dec 22 16:57:32.927647 2018] [fcgid:warn] [pid 24975] [client 93.235.82.78:38548] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:57:46.719141 2018] [fcgid:warn] [pid 15864] [client 93.235.82.78:38599] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:57:52.536825 2018] [fcgid:warn] [pid 33970] [client 93.235.82.78:38642] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:58:26.362861 2018] [fcgid:warn] [pid 59733] [client 93.235.82.78:38792] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
[Sat Dec 22 16:58:34.871927 2018] [fcgid:warn] [pid 17641] [client 93.235.82.78:38809] mod_fcgid: stderr: PHP Deprecated:  Methods with the same name as their class will not be constructors in a future version of PHP; modDelivery has a deprecated constructor in /var/www/vhosts/schnaepchenpiet.shop/test.schnaepchenpiet.shop/includes/extra/modules/product_info_end/setDeliveryDate.inc.class on line 4, referer: https://test.schnaepchenpiet.shop/
Das hört sich nach etwas an, was du unbedingt fixen musst, aber nicht Ursache deines Problems ist. Aber die Hinweise darauf, dass deine Shopsoftware total veraltet und wahrscheinlich einige Sicherheitslücke dadurch hat, verhärten sich nur - von Thread zu Thread ;)