6.0.0-beta1
9/5/25

[#2053] serialize problem
Summary serialize problem
Queue Ulaform
Type Bug
State Resolved
Priority 1. Low
Owners
Requester david (at) tmv (dot) gov (dot) tw
Created 05/31/2005 (7402 days ago)
Due
Updated 06/10/2005 (7392 days ago)
Assigned 06/06/2005 (7396 days ago)
Resolved 06/09/2005 (7393 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
06/10/2005 10:54:42 AM Jan Schneider Comment #12 Reply to this comment
Committed, thanks.
06/10/2005 03:26:05 AM david (at) tmv (dot) gov (dot) tw Comment #11
New Attachment: sql.php.patch Download
Reply to this comment
Thank you ,chuck & jan.

Mean while,getField() also require to fix ,patch was attached.



David
06/09/2005 08:59:53 AM Jan Schneider Comment #10
State ⇒ Resolved
Reply to this comment
Fixed in CVS.
06/09/2005 03:01:03 AM   New Attachment: edit_field.gif Download
 
06/09/2005 03:00:48 AM   New Attachment: new_field.gif Download
 
06/09/2005 03:00:32 AM   New Attachment: edit_form.gif Download
 
06/09/2005 02:59:06 AM david (at) tmv (dot) gov (dot) tw Comment #9
New Attachment: new_form.gif Download
Reply to this comment
David-

We pass the data through Horde_Serialize(), so I'm not surprised that
it's not the original data. That's how we handle form_params, too, so
do those work for you? I'm not sure what the difference is, if you
could have a peek at the code that'd be great.
Both saveForm() & saveField () save UTF7 format(i guess) to database 
now,but some columns can't be tarnsfered  to chinese string while 
click edit form/field.



Screenshot for your information:

new_form.gif : New a form which form's name in chinese.

edit_form.gif  : Edit that form,form's name no more in chinese.

new_field.gif : New a field which values and prompt in chinese.

edit_field.gif : Edit that field,value & prompt no more in chinese.



David




06/08/2005 07:25:20 PM Chuck Hagenbuch Comment #8 Reply to this comment
I really don't know what you're getting at. Can you answer the 
question about form_params vs. field_params?
06/08/2005 08:11:00 AM   New Attachment: serialize-in-url.php Download
 
06/08/2005 04:03:11 AM david (at) tmv (dot) gov (dot) tw Comment #7
New Attachment: serialize-in-phpshell.jpg Download
Reply to this comment
That's a weird thing about serialize function in Horde H3 (with php 4.3.10)

The length of chinese string in Horde's php-shell was serialize as 3x 
by every single chinese not 2x ,i think that is why cause this issue.

Screenshot : serialize-in-phpshell.jpg will explain what i'd say.



On the other hand,running script in serialize-in-phpshell.jpg  instead 
of  http://210.241.49.68/~txg16/serialize-in-url.php ,and this time 
string length serialized  correctly with 2x by every single chinese.




06/06/2005 06:27:42 PM Chuck Hagenbuch Comment #6 Reply to this comment
David-



We pass the data through Horde_Serialize(), so I'm not surprised that 
it's not the original data. That's how we handle form_params, too, so 
do those work for you? I'm not sure what the difference is, if you 
could have a peek at the code that'd be great.
06/06/2005 11:30:48 AM Jan Schneider Comment #5 Reply to this comment
Huh?
06/06/2005 04:28:43 AM david (at) tmv (dot) gov (dot) tw Comment #4 Reply to this comment
The length in field_params about values was fixed,but not store as
the original multibyte string,eg. enter chinese in th form.

David

a:2:{s:6:"values";s:13:"+kHhT1lA8geo-";s:6:"prompt";s:0:"";}
length=13 (OK)

string=+kHhT1lA8geo- (Not OK)
06/06/2005 04:26:47 AM david (at) tmv (dot) gov (dot) tw Comment #3 Reply to this comment
The length in field_params about values was fixed,but not store as the 
original multibyte string,eg. enter chinese in th form.



David



a:2:{s:6:"values";s:13:"+kHhT1lA8geo-";s:6:"prompt";s:0:"";}

                                          ^^^^^^^^^^^^^^^^^
06/06/2005 03:55:46 AM Chuck Hagenbuch Comment #2
State ⇒ Feedback
Reply to this comment
05/31/2005 08:30:57 AM david (at) tmv (dot) gov (dot) tw Comment #1
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ serialize problem
Queue ⇒ Ulaform
State ⇒ Unconfirmed
Reply to this comment
Incorrect serialized paramater was saved to 
ulaform_fields:field_params,if use non ASCII in it.



For example,create new form with "Drop down list" type ,and use 
multibyte in values.



Here are the record point to the it.

a:2:{s:6:"values";s:15:"??1,??2";s:6:"prompt";s:0:"";}

should be  fixed as ==>

a:2:{s:6:"values";s:11:"??1,??2";s:6:"prompt";s:0:"";}




Saved Queries