1 Attachment(s)
Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
Hello guys,
I have the following error in my debug log which I recently noticed after installing the GDPR plugin from here from RYK post #144 who unfortunately provides no support from what I gather in the threads.
https://www.zen-cart.com/showthread....76#post1366876
PHP Warning: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE - assumed 'TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE' (this will throw an Error in a future version of PHP) in /Admin/customers.php on line 1303.
I also noticed in the admin/customers that it shows up like this which isn’t normal.
Attachment 19199
Any help would be greatly appreciated.
Many thanks
Nathan
Re: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
BTW this is line 1303 from above in admin/customers.php.
<td class="dataTableContent text-right"><?php echo $customer['customers_id'] . ($zc_address_book_count == 1 ? TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE : sprintf(TEXT_INFO_ADDRESS_BOOK_COUNT, zen_href_link(FILENAME_CUSTOMERS, 'action=list_addresses' . '&cID=' . $customer['customers_id'] . ($_GET['page'] > 0 ? '&page=' . $_GET['page'] : '')), $zc_address_book_count)); ?></td>
Re: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE should be already defined in admin/includes/languages/english/customers.php
I would check that file.
Re: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
Thanks for the hint Simon,
I checked the file admin/includes/languages/english/customers.php
as you said and I saw on:
Line 63
define('TEXT_INFO_ADDRESS_BOOK_COUNT', ' | 1 of ');
Does that mean there's a mismatch as it says TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE in original log file? If so, which file should I correct and should I include the _SINGLE bit at end or remove it?
PHP Warning: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE - assumed 'TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE' (this will throw an Error in a future version of PHP) in /Admin/customers.php on line 1303.
Thanks very much.
Nathan
Re: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
@himmon, look at the header-comment in that /admin/includes/english/customers.php. For zc157, it should read
Code:
<?php
/**
* @copyright Copyright 2003-2020 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: Scott C Wilson 2020 Apr 08 Modified in v1.5.7 $
*/
Re: Use of undefined constant TEXT_INFO_ADDRESS_BOOK_COUNT_SINGLE
Thanks Lat9, getting closer :smile:
<?php
/**
* @package admin
* @copyright Copyright 2003-2016 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: Author: DrByte Sun Oct 18 23:54:03 2015 -0400 Modified in v1.5.5 $
*/
Need to compare RYK GDPR Plugin gdpr4zc156c.zip admin/includes/languages/english/customers.php and merge changes with original copy of 1.5.7 customers.php
Not sure how I missed an overwrite as usually check for merges.
Thanks guys