php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #45781 request: more than 1 parameter for userdata in function "array_walk"
Submitted: 2008-08-11 03:55 UTC Modified: 2008-08-11 23:02 UTC
From: Ultrasick at gmx dot de Assigned:
Status: Not a bug Package: Feature/Change Request
PHP Version: 5.2.6 OS: irrelevant
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
4 - 1 = ?
Subscribe to this entry?

 
 [2008-08-11 03:55 UTC] Ultrasick at gmx dot de
Description:
------------
The syntax of the function "array_walk" is currently as below:

bool array_walk(array &$array, callback $funcname [, mixed $userdata])

It would be an improvement if there would be more than 1 parameter for the user data available. Similar like for the array_merge function:

bool array_walk(array &$array, callback $funcname [, mixed $userdata1 [, mixed $userdata2 [, mixed $...]]])


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-08-11 03:56 UTC] Ultrasick at gmx dot de
changed summary because of wrong word in it
 [2008-08-11 18:57 UTC] johannes@php.net
You can simply use an array for your data items...
 [2008-08-11 23:00 UTC] Ultrasick at gmx dot de
yes I am doing that at the moment as a work-around ... packing the data in an array and unpacking it again inside the function. But why is this a bogus feature request?
 [2008-08-11 23:02 UTC] Ultrasick at gmx dot de
sorry, didn't want to change the summary
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Jun 26 18:01:31 2024 UTC