Last modified: 2014-10-20 19:02:16 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T72325, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 70325 - Warning: mb_strpos() expects parameter 3 to be long, string given in /srv/web/extensions-mainwiki-git/ParserFunctions/ParserFunctions_body.php on line 603
Warning: mb_strpos() expects parameter 3 to be long, string given in /srv/web...
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
ParserFunctions (Other open bugs)
REL1_22-branch
All All
: Normal normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
https://wiki.piratenpartei.de/Benutze...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-09-03 06:22 UTC by Purodha Blissenbach
Modified: 2014-10-20 19:02 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Purodha Blissenbach 2014-09-03 06:22:25 UTC
Warning: mb_strpos() expects parameter 3 to be long, string given in /srv/web/extensions-mainwiki-git/ParserFunctions/ParserFunctions_body.php on line 603

Tis message occurs in 
https://wiki.piratenpartei.de/Benutzer:Stimmbürger
both in page view and previews but strangely not when you select a page version.
The most recent version of the page is of 02:33, 14. Jan 2014‎

Installed ParserFunctions  Ver. 1.6.0 (a07a84f) of 21:49, 1. Apr 2014
Comment 1 Purodha Blissenbach 2014-09-25 22:25:39 UTC
There is another instance of this bug at http://wiki.piratenpartei.de/Benutzer:CaptCarrot
Comment 2 Jan Reininghaus 2014-10-20 19:02:16 UTC
An easy way to reproduce this issue was found by Allan Wegan, simply add the following to a wiki page:
{{#pos:haystack|needle|}}

Removing the last | symbol makes the warning go away.

This issue could be fixed by replacing the line in ParserFunctions_body.php with:
$pos = mb_strpos( $inStr, $inNeedle, intval( $inOffset ) );

In current version 1.6.0 it's in line 603. I could also reproduce this issue with current master (0b96cba), here the problem is in line 627.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links