user notice: The _custom_breadcrumbs_get_breadcrumb() function called token replacement with an array rather than a string for $text in /public_html/drupal/sites/all/modules/token/token.module on line 263.

Updated the token module today and this error showed up. Can someone look into this? Thank you.

Comments

boobaa’s picture

fcaceres71’s picture

Nada I still get the error after using patch #8 and patch #14.

tomrenner’s picture

Same here. Subscribe.

wlcable’s picture

I am also getting this error after updating to the most recent version...

ltrain’s picture

I am also getting the error.

bartezz’s picture

Also reporting this error!

Anonymous’s picture

also getting this error

le dendrite’s picture

Subscribing.

I'm getting a similar error. After updating Token

user notice: The _custom_links_build_links() function called token replacement with an array rather than a string for $text in.... /sites/default/modules/token/token.module on line 263.

However the custom links on the pages pulling the error are still working...

Drupal 6.22
Token 6.x-1.18
Custom Links 6.x-1.4

venusrising’s picture

Status: Closed (duplicate) » Active

We too are getting this error. patches not working. DB is filling up with entries

MGN’s picture

Category: bug » support

Have you tried using the latest token 6.x-1.x-dev? Reading Dave Reid's reply in #1327960: Invalid use of token_replace API - causes preg_match_all errors in token module, it seems like he restored the original functionality.

At this point in 6.x-1.x-dev (and eventually in the future 6.x-1.19 release) of Token there are no more warnings thrown if $text is an array and token replacement should just work as before.

I just tried the latest dev and don't see any problems (though I was able to verify the problem in 6.x-1.18). I think the way to "fix" this at this point is to use token 6.x-1.x-dev until 6.x-1.19 is released. So long as token maintains this functionality in the 6.x-1.x branch (as Dave's comment indicates), I don't see a reason to change the 6.x-2.x version of custom breadcrumbs. Note that the D7 version of custom breadcrumbs has already been modified to use a string instead of an array because of the new token_replace in the D7 API. So there shouldn't be a problem in the D7 version either.

MGN’s picture

I take it back. It does make sense to adjust 6.x-2.x slightly to better agree with 6.x-1.x and the token API (as well as the D7 branch). Note: I committed the fix (more or less) in #5 of #1327960: Invalid use of token_replace API - causes preg_match_all errors in token module by Patrizio to the 6.x-2.x-dev branch. Note the patches in #8 or #14 of that issue wouldn't work correctly for 6.x-2.x (unless you are just using node type tokens - #8 was the basis for the patch used in the 6-x.2-x branch).

jasom’s picture

Category: support » bug
Status: Active » Fixed

#8 solved my problem, tnx

venusrising’s picture

Status: Fixed » Active

@MGN We are using 6x2 RC1 on a production site. Is there a patch we can apply? BTW for those of use with production sites Dev Token is not a good answer due to potential stability issues with other modules.
Custom Breadcrumbs 6x2 RC1 has been awesome, works great with the exception of DB error not above. It still functions and we are using it with views etc and it does a great job.

nasi’s picture

Same issue here. It would be great to ideally have a new point release that includes a fix for this issue, or a patch specific to this bug. I'm not keen on pushing a dev release into production.

It's been a while since rc1 was released, is there an idea of a timeframe for another release (e.g. rc2)?

venusrising’s picture

Priority: Normal » Critical

This issue is filling up our logs to the point that valuable data like new users events as well as spammers are not be logged since this is filling up our logs and pushing everything else out.

We are using 6x2 RC1 Please can someone let us know how to fix these massive log dumps.
.

jimkont’s picture

Same here...
subscribing

paulo_graca’s picture

StatusFileSize
new820 bytes

I've just created this patch for a workaround.
The problem is with the most recent version of Token in D6. I hope it helps!

venusrising’s picture

@paulo_graca

Thanks before I proceed can you tell us what the patch does as this is a production site but the DB logs are a killer so we are very grateful for your help.

venusrising’s picture

nasi’s picture

Which version of custom_breadcrumbs is this patch made against? It doesn't seem to correspond to the code for 2.0-rc1.

mmachina’s picture

update with the DEV version and the error goes away!

finedesign’s picture

Same problem here with 6.x-2.0-rc1

rich.yumul’s picture

StatusFileSize
new805 bytes

Here's a patch for 6.x-2.0-rc1 for this issue.

adijeff’s picture

Thanks Rich. #23 worked for me on the January 8 version of 6.x-2.0-rc1

slucas’s picture

Thanks the patch works but not automatically, I need to patch manually.
Thanks

drozas’s picture

StatusFileSize
new756 bytes

Thanks Rich. #25 the patch did not work automatically for me neither, I attach a new one (I think it was because of the way it was generated).

sgabe’s picture

Priority: Critical » Major
Status: Active » Reviewed & tested by the community

The patch in #26 seems to work.

caspercash’s picture

#8 solved my problem too! Thanks!

fenstrat’s picture

Status: Reviewed & tested by the community » Closed (duplicate)

This problem has already been resolved and committed to both 6.x-1.x and 6.x-2.x branch in #1327960-42: Invalid use of token_replace API - causes preg_match_all errors in token module

Anonymous’s picture

Status: Closed (duplicate) » Active

The problem is still in 6.x-2.0-rc1

fenstrat’s picture

Status: Active » Closed (duplicate)
Anonymous’s picture

@fenstat, sorry assumed the rc had a later date than the dev version. I must have missed the year difference.

fenstrat’s picture

@CompuBase, no worries, I've done that myself more than once.

dkane’s picture

I can confirm that #26 also worked for me as well.

Thank you everyone for your hard work on this!

fenstrat’s picture

@dkane, This problem has already been resolved and committed to both 6.x-1.x and 6.x-2.x branch in #1327960-42: Invalid use of token_replace API - causes preg_match_all errors in token module. This issue is a *duplicate* of that issue.

I believe I'm beginning to sound like a broken record here.

mmachina’s picture

Version: 6.x-2.x-dev » 6.x-2.0-rc1

I'm using 6.x-2.0-rc1 and the patch in comment #26 worked perfecto!!!

pcoughlin’s picture

Patch in #26 solved the problem. Tested with 6.x-2.0-rc1

rrafferty’s picture

Sorry to be dense, but short of running patch at the command line is there anyway to fix this? I do not have access to command line. My log file, however, is growing by the minute.

rrafferty’s picture

If you want to apply this patch manually, here is a tutorial. It was actually pretty easy.

http://drupal.org/node/534548

cknoebel’s picture

#26 works for me, thanks for the patch.

bessone’s picture

#26 works for me too, thanks

arlina’s picture

#26 did the trick. thanks!

fenstrat’s picture

Please see #35.

dewolfe001’s picture

I used the latest dev version of Token and that remedied my problems.

MatteNoob’s picture

I also updated to the latest dev version of token (token-6.x-1.x-dev.tar) and it resolved the issue for me too.

MatteNoob’s picture

Issue summary: View changes

Token module updated