php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #15244 array_splice acts like array_splice
Submitted: 2002-01-27 09:53 UTC Modified: 2002-01-27 11:48 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: tobias at pfadfinder-kirchzarten dot de Assigned: jan (profile)
Status: Closed Package: Documentation problem
PHP Version: 4.0.5 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: tobias at pfadfinder-kirchzarten dot de
New email:
PHP Version: OS:

 

 [2002-01-27 09:53 UTC] tobias at pfadfinder-kirchzarten dot de
both functions give back the same result:
array_slice($array,1,5);
is eaqual to:
array_splice($array,1,5);

but my phpDocumentation tells me that there should be a "small" diverence

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-01-27 09:57 UTC] jan@php.net
can you please provide the $array you are using?

 [2002-01-27 11:12 UTC] tobias at pfadfinder-kirchzarten dot de
it's like this one :
$array = array( [0] => firstentry,[1] => secondtentry,[2] => thirdentry,[...etc...]);
 [2002-01-27 11:23 UTC] jan@php.net
array_slice is used to extract values from an existing array without modifying the orinial array. array_splice really extracts the array elements and so modifies the array. however both return an array containing the extracted elements, which _have_to_be_ equal. I call thi a documentation problem, assigning to myself. thank you for reporting.
 [2002-01-27 11:48 UTC] jan@php.net
fixed in CVS. closing
 [2020-02-07 06:12 UTC] phpdocbot@php.net
Automatic comment on behalf of jan
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=0e4bc74baffb5644d8be169fe8304a5e6be7bd60
Log: - fixed #15244
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Oct 06 07:01:27 2024 UTC