Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-12-10 13:48:23

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Deprecated error on 4.4.1 with PHP 5.3.5

I have some sites on Joyent which just upgraded their servers – and now notice an error message on screen as a result:

Deprecated: Function split() is deprecated in /users/home/me/web/textpattern-4.4.1/textpattern/lib/txplib_misc.php(653) : eval()'d code on line 471

Its a multi-site install running 4.4.1. Its clearly a PHP upgrade issue since the latest version on Joyent is now 5.3.5.

Offline

#2 2011-12-10 15:10:49

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

That’s not caused by Textpattern itself. And if it’s not caused by Textpattern, then It’s probably caused by a plugin. Check all your plugins by disabling every plugin one by one until the message disappears.

Offline

#3 2011-12-10 15:41:41

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Deprecated error on 4.4.1 with PHP 5.3.5

Hi,
maybe one of your sites uses the MLP?
In case this is a known and easily fixable bug, just have a look in the MLP forum for a solution.

Offline

#4 2011-12-11 05:23:23

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

Mmm. I thought it could be a plugin, but its not MLP. Maybe arc_twitter which is used on that site. I’ll investigate further.

Offline

#5 2011-12-11 10:12:21

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,271
Website GitHub

Re: Deprecated error on 4.4.1 with PHP 5.3.5

fwiw, zem_contact_reborn v4.0.3.20 still uses split(), although it’s not on line 471. Keep forgetting to mention it to ruud.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#6 2011-12-11 13:10:41

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

Looks like it was tru_tags 3.5. Thanks for the help.

Offline

#7 2012-04-19 21:04:23

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 999
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

I’m getting the same error on my development machine, which I recently upgraded to OS 10.7 Lion, using the native PHP. I’m about halfway through opening each plugin in Edit mode and searching for split()s, and I wonder if there’s a plugin that lets you search plugin code like smd_where_used.

Offline

#8 2012-04-19 21:11:04

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,271
Website GitHub

Re: Deprecated error on 4.4.1 with PHP 5.3.5

johnstephens wrote:

I wonder if there’s a plugin that lets you search plugin code like smd_where_used.

You could try SQL:

select name from txp_plugin where code like '%split(%'

but beware that it’ll pick up any javascript calls with the string.split() method in them, so it might not be much use.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#9 2012-04-20 05:21:33

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 999
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

That’s excellent, Stef— thanks! I did it the slow dumb way on one site, but I can still use this trick for the others. At least it narrows the search down significantly!

Offline

#10 2012-12-20 13:43:56

kees-b
Member
From: middelburg, nl
Registered: 2004-03-03
Posts: 235
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

On a site, also still on txp 4.4.1, I get this deprecated split error after a PHP upgrade 5.3.5. After doing Stef’s excellent query these plugins are returned:

l10n
chh_article_lib
zem_contact_reborn

Is it safe to edit the code of these plugins and change all instances of ‘split’ to ‘explode’?
By the way chh_related_articles, that uses the chh_article_lib is an orphaned plugin but is still working on 4.4.1.
Will it break after a txp update to 4.5.4? Is the updated MLP split-cleaned?

-kees

Offline

#11 2012-12-20 23:00:25

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

@kees: Yes (on changing split)

Offline

#12 2012-12-21 09:21:27

kees-b
Member
From: middelburg, nl
Registered: 2004-03-03
Posts: 235
Website

Re: Deprecated error on 4.4.1 with PHP 5.3.5

thanks ruud!

Offline

Board footer

Powered by FluxBB