Zen Cart Logo
Forums / Upgrading to 1.5.x / Product Won't Entirely copy over when using Duplicate

Product Won't Entirely copy over when using Duplicate

Views: 1,060

Results 1 to 8 of 8
27 Aug 2012, 10:42 PM
#1
valsurfer101 avatar

valsurfer101

New Zenner

Join Date:
Feb 2012
Posts:
73
Plugin Contributions:
0

Product Won't Entirely copy over when using Duplicate

I use the copy/duplicate feature a lot and since i have done the upgrade when I try to copy or duplicate a product the name is the Only thing that actually copies over. this is the only last thing that has shown up in my console and i recopied the collect_info.php file over from the original

[26-Aug-2012 09:45:05] PHP Warning: htmlspecialchars() [function.htmlspecialchars]: Invalid multibyte sequence in argument in /home/user/mysite/myrenamed-admin/includes/modules/product/collect_info.php on line 401
not sure if the two were related but putting the new collect_info.php file didn't fix my copying over problem.

any one know the fix to this.

28 Aug 2012, 6:20 PM
#3
valsurfer101 avatar

valsurfer101

New Zenner

Join Date:
Feb 2012
Posts:
73
Plugin Contributions:
0

Re: Product Won't Entirely copy over when using Duplicate

I did everything on the link and unfortunately still everything copies over except for the description. :(

6 Sep 2012, 4:55 PM
#4
valsurfer101 avatar

valsurfer101

New Zenner

Join Date:
Feb 2012
Posts:
73
Plugin Contributions:
0

Re: Product Won't Entirely copy over when using Duplicate

Anyone have any other reccomendations?

6 Sep 2012, 5:01 PM
#5
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,771
Plugin Contributions:
9

Re: Product Won't Entirely copy over when using Duplicate

I think you need to investigate the UTF-8 versus ISO-8859-1 situation. If you are set to use UTF-8 and htmlspecialchars() is not set to that as well, you will get the error you're getting.

7 Sep 2012, 6:55 PM
#6
valsurfer101 avatar

valsurfer101

New Zenner

Join Date:
Feb 2012
Posts:
73
Plugin Contributions:
0

Re: Product Won't Entirely copy over when using Duplicate

so i found this in the functions_general.php its the only file that has any UTF8 written in it.

* convert supplied string to UTF-8, dropping any symbols which cannot be translated easily
* useful for submitting cleaned-up data to payment gateways or other external services, esp if the data was copy+pasted from windows docs via windows browser to store in database
*
* @param string $string
*/
 function charsetConvertWinToUtf8($string) {
   if (function_exists('iconv')) $string = iconv("Windows-1252", "ISO-8859-1//IGNORE", $string);
   $string = htmlentities($string, ENT_QUOTES, 'UTF-8');
   return $string;
 }

/**
* Convert supplied string to/from entities between charsets, to sanitize data from payment gateway
* @param $string
* @return string
*/
 function charsetClean($string) {
   if (CHARSET == 'UTF-8') return $string;
   if (function_exists('iconv')) $string = iconv("Windows-1252", CHARSET . "//IGNORE", $string);
   $string = htmlentities($string, ENT_QUOTES, 'UTF-8');
   $string = html_entity_decode($string, ENT_QUOTES, CHARSET);
   return $string;
 }
7 Sep 2012, 7:21 PM
#7
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Product Won't Entirely copy over when using Duplicate

Those functions are unrelated.

7 Sep 2012, 7:24 PM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Product Won't Entirely copy over when using Duplicate

Since you haven't answered the questions asked in the Posting Tips, I'll ask a bunch directly instead, plus some more:
What's your PHP version?
What addons do you have installed?
How exactly did you "upgrade"?
What is the CHARSET defined to in your admin english.php file? Is it defined in any other files in your admin?
What is the DB_CHARSET in your configure.php files?
What's the collation set to on your products_description table? and also on the products_description field inside that table?