Page 1 of 1

IS_PRODUCT_PRODUCTS_DISPLAY_ROW

Posted: Sun May 21, 2023 4:19 pm
by Xpajun
Again 1.0.7.4

The folowing error is filling up my error Page:

Code: Select all

[21-May-2023 13:01:52 UTC] PHP Warning:  Use of undefined constant IS_PRODUCT_PRODUCTS_DISPLAY_ROW - assumed 'IS_PRODUCT_PRODUCTS_DISPLAY_ROW' (this will throw an Error in a future version of PHP) in /home/**********/public_html/store/templates/default/includes/components/product_listing.php on line 98

lines 89 through 101:

Code: Select all

    if ( $item%IS_PRODUCT_PRODUCTS_DISPLAY_ROW_SM == 0 ) $prod_list_contents .= '<div class="w-100 d-none d-sm-block d-md-none"></div>' . PHP_EOL;
    if ( $item%IS_PRODUCT_PRODUCTS_DISPLAY_ROW_MD == 0 ) $prod_list_contents .= '<div class="w-100 d-none d-md-block d-lg-none"></div>' . PHP_EOL;
    if ( $item%IS_PRODUCT_PRODUCTS_DISPLAY_ROW_LG == 0 ) $prod_list_contents .= '<div class="w-100 d-none d-lg-block d-xl-none"></div>' . PHP_EOL;
    if ( $item%IS_PRODUCT_PRODUCTS_DISPLAY_ROW_XL == 0 ) $prod_list_contents .= '<div class="w-100 d-none d-xl-block"></div>' . PHP_EOL;
    $item++;
  }

  echo $GLOBALS['OSCOM_Hooks']->call('filter', 'drawForm');

(line 98)  echo '<div class="' . IS_PRODUCT_PRODUCTS_DISPLAY_ROW . '">' . PHP_EOL;
    echo $prod_list_contents;
  echo '</div>' . PHP_EOL;

It's not stopped anything running (currently) just being inconvenient when checking errors

Re: IS_PRODUCT_PRODUCTS_DISPLAY_ROW

Posted: Sun May 21, 2023 6:42 pm
by ecartz
IS_PRODUCT_PRODUCTS_DISPLAY_ROW is in the database. So You should be able to copy the insert line from https://github.com/CE-PhoenixCart/Phoen ... x.sql#L779

Re: IS_PRODUCT_PRODUCTS_DISPLAY_ROW

Posted: Sun May 21, 2023 9:20 pm
by Xpajun
ecartz wrote: Sun May 21, 2023 6:42 pm IS_PRODUCT_PRODUCTS_DISPLAY_ROW is in the database. So You should be able to copy the insert line from https://github.com/CE-PhoenixCart/Phoen ... x.sql#L779
Thank you Matt - fixed - not sure how it got left out of the database though
I think I need to get back to1.0.8.19/20 and get that on line