Project

General

Profile

Actions

Bug #46019

closed

htmlspecialchars in class.tslib_content.php

Added by Tomasz Krawczyk about 11 years ago. Updated about 11 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2013-03-04
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.5
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

I have lots of such errors in my PHP error log:

[04-Mar-2013 06:35:49 UTC] PHP Warning: htmlspecialchars() expects parameter 1 to be string, array given in D:\Sites\www.mysite.pl\typo3_src\typo3\sysext\cms\tslib\class.tslib_content.php on line 5891

If I add this: var_dump($LD['target']); in line 5889 I can see this at the beginning of the output:

string(6) "_blank" string(6) "_blank" string(6) "_blank" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) "" string(0) ""

I noticet this on TYPO3 version 4.5.23, IIS 6.0, PHP 5.3.17, multidomain but single language. I see no other problems with this site. Can anyone help me?

Actions #1

Updated by Markus Klein about 11 years ago

Since this happens in one of the most widely used methods, namely typolink(), this can have a couple of root causes:

  • Misused stdWrap on target in Typoscript
  • Check if any extension is registered to the hook $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tstemplate.php']['linkData-PostProc']. If so, disable it and check again.
  • Otherwise more or less any call to typolink() with a faulty configuration for the target may be the reason.
Actions #2

Updated by Dmitry Dulepov about 11 years ago

Could you ask questions in mailing lists (http://lists.typo3.org/)? Bug tracker is for bugs, not for questions.

Thank you!

Actions #3

Updated by Stefan Galinski about 11 years ago

  • Status changed from New to Needs Feedback
Actions #4

Updated by Tomasz Krawczyk about 11 years ago

I used TypoScript Analyzer to check all my TypoScript and didn't find any problems.
The only extension on my installation that uses this hook is RealUrl but I don't have such issue on another installations.
This error I can see in my log files since end of August. Since this time I updated TYPO3 a few times and I also updated 14 extensions.

It looks like it was my local problem. So, I will ask for help on the forum.

Thanks for hints and please close this bug.

Actions #5

Updated by Stefan Galinski about 11 years ago

  • Status changed from Needs Feedback to Closed
Actions

Also available in: Atom PDF