Issues

ZF-5414: Non ASCII characters break the columns when input is UTF-8 encoded

Issue Type: Bug Created: 2009-01-06T06:21:41.000+0000 Last Updated: 2009-01-08T10:23:54.000+0000 Status: Resolved Fix version(s): - 1.8.0 (30/Apr/09)

Reporter: Jean-Marc Fontaine (jmf) Assignee: Ben Scholzen (dasprid) Tags: - Zend_Text_Table

Related issues: Attachments: - Zend_Table.php

Description

Non ASCII characters break the columns when input is UTF-8 encoded.

The problem is located in the Zend_Text_Table_Column class on line 229. The str_pad() function is used and it is not overloaded by mbstring extension so it fails calculating correctly the string length.

Comments

Posted by Thomas Weidner (thomas) on 2009-01-06T07:54:11.000+0000

Iconv has to be used instead of mbstring because it's available in default php installations. Mbstring is only allowed to be used when there is no other way.

Posted by Ben Scholzen (dasprid) on 2009-01-06T13:14:47.000+0000

Jean, can you please submit a test case to demonstrate, how the column breaks?

Posted by Jean-Marc Fontaine (jmf) on 2009-01-07T03:44:20.000+0000

Test case for the bug

Posted by Ben Scholzen (dasprid) on 2009-01-08T10:23:54.000+0000

Fixed in r13556 and merged into 1.7 branch with r13557

Have you found an issue?

See the Overview section for more details.

Copyright

© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.

Contacts