field_html_trim_truncate() uses [] shorthand for arrays which is not supported prior to PHP 5.4. Otherwise only three strings are affected so could be reverted to old array() syntax for compatibility with legacy versions (unfortunately, I'm still stuck with 5.3 on my host).

Comments

kurapov created an issue. See original summary.

alexverb’s picture

Version: 7.x-1.3 » 7.x-1.x-dev
Category: Feature request » Task
Status: Active » Needs review
StatusFileSize
new993 bytes

Yup, the new truncate function was copied straight from CakePHP. I didn't notice the new shorthands. I would like to revert to PHP 5.3 compatible arrays. But I'm finding only two occurances. Could you test this patch before I put this into a new version?

Thx for letting me know about this issue.

kurapov’s picture

There's one more, right at the beginning.

  • kurapov authored 91a7344 on 7.x-1.x
    Issue #2696857 by kurapov, alexverb: PHP 5.4 should be marked as a...
alexverb’s picture

Status: Needs review » Closed (fixed)

Committed to field_html_trim 7.x-1.4. Thanks for your help.