Problem/Motivation
The db log is now full of error messages:
Deprecated function: iconv_set_encoding(): Use of iconv.internal_encoding is deprecated in MarketplaceWebServiceProducts_Client->__construct() (line 848 of /home/vnb/public_html/sites/all/modules/amazonMWS/libraries/nonapod/AmazonMWS/MarketplaceWebServiceProducts/Client.php).
I claim this was triggered by a hoster changing the default PHP version to 5.6. The error is not reported on PHP 5.4.3
Note that the actual error is in the external Nanopod library code and not the MWS module.
The offending code is:
iconv_set_encoding('output_encoding', 'UTF-8');
iconv_set_encoding('input_encoding', 'UTF-8');
iconv_set_encoding('internal_encoding', 'UTF-8');
Proposed resolution
Not sure? I have not yet investigated the fix.
Comments
Comment #1
Anonymous (not verified) commentedgiffenk created an issue.
Comment #2
Anonymous (not verified) commentedI found a note in the php documentation regarding this issue:
http://php.net/manual/en/function.iconv-set-encoding.php#116169
a newer note provides more information:
http://php.net/manual/en/function.iconv-set-encoding.php#119888
Comment #3
travis-bradbury commentedLooks like there's 9 places in nonapod/AmazonMWS that should be fixed:
Here's the source of the information from the comments on the iconv_* documentation about setting default_charset instead :
http://php.net/manual/en/iconv.configuration.php
For this, UTF-8 is already the default since PHP5.6. http://php.net/manual/en/ini.core.php#ini.default-charset