Anthony Ryan
d6dc2be3c5
Add a warning about the subtle global state in legacy random functions ( #5414 )
...
Fixes https://github.com/php/php-src/issues/21351
Replaces https://github.com/php/php-src/pull/21352
2026-03-24 00:23:46 +01:00
Takuya Aramaki
4a1dedc24b
array_rand() may throw ValueError since 8.0 ( #3230 )
...
array_rand() throws ValueError if empty array is given or num is out of range
Co-authored-by: Gina Peter Banyard <girgias@php.net >
2024-03-05 22:33:33 +00:00
Tim Düsterhus
fc1e94a9c2
random: Improve the non-CSPRNG warning ( #2009 )
...
* Strengthen the wording in `&caution.cryptographically-insecure;`
It’s not: “should not”, it’s “must not”.
* random: Unify use of `&caution.cryptographically-insecure;`
- The warning goes last.
- It is actually applied to all functions.
* random: Completely rewrite the `&caution.cryptographically-insecure;` warning
* random: Revert indentation changes to lcg-value.xml
2022-11-17 11:53:00 +01:00
Tim Düsterhus
52c495140b
random: Clean up cross-references for randomness related functions ( #2008 )
...
* random: Reference the corresponding Randomizer methods in random_(bytes|int)
* random: Cross-reference the Randomizer in `str_shuffle()`
* random: Cross-reference the Randomizer in `shuffle()`
* random: Cross-reference the Randomizer in `array_rand()`
* random: Cross-reference `random_bytes()` in `uniqid()`
* random: Do not cross-reference `uniqid()` in `openssl_random_pseudo_bytes()`
uniqid() really is no good alternative to *anything*. In the vast majority of
cases it is better replaced by `bin2hex(random_bytes(…))`.
* random: Replace the `mt_rand()` cross-reference in `openssl_random_pseudo_bytes()` with `random_int()`
random_int() is a CSPRNG like openssl_random_pseudo_bytes(), mt_rand() is not.
2022-11-15 11:19:28 +01:00
Christoph Michael Becker
cd943f94a0
Generate array methodsynopses based on stubs
...
Partial merge of <https://github.com/php/doc-en/pull/266 >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@351860 c90b9560-bf6c-de11-be94-00142212c4b1
2020-12-04 00:35:15 +00:00
Christoph Michael Becker
282140eb7d
Note that the order of returned keys is deterministic
...
Patch contributed by Larry Garfield <larry@garfieldtech.com >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350939 c90b9560-bf6c-de11-be94-00142212c4b1
2020-10-19 07:35:23 +00:00
Christoph Michael Becker
9af43469f4
Remove more changelog entries, mostly from PHP 5.2 era
...
Patch contributed by Sobak <msobaczewski@gmail.com >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@350654 c90b9560-bf6c-de11-be94-00142212c4b1
2020-09-26 13:52:31 +00:00
Christoph Michael Becker
126eefa0db
Clarify refpurpose
...
As suggested by a patch provided by an anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344984 c90b9560-bf6c-de11-be94-00142212c4b1
2018-05-08 12:29:26 +00:00
Christoph Michael Becker
b45d8c1772
Nested <link>s can't work
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344693 c90b9560-bf6c-de11-be94-00142212c4b1
2018-04-17 16:10:01 +00:00
Andrey Gromov
bb8db2ad12
remove redurant tags "tbody"
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@341936 c90b9560-bf6c-de11-be94-00142212c4b1
2017-02-20 22:35:01 +00:00
Maciek Sokolewicz
ce3996c403
documented the change in behaviour due to aliasing of rand to mt_rand in PHP 7.1.0
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@341933 c90b9560-bf6c-de11-be94-00142212c4b1
2017-02-20 22:01:10 +00:00
Christoph Michael Becker
fb0122dd8b
Fix #64386 : No warning on insecure pseudo-random generators
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@339348 c90b9560-bf6c-de11-be94-00142212c4b1
2016-06-14 14:52:22 +00:00
Maciej Sobaczewski
8b5940cade
Remove changelogs for PHP 4 - 2nd round
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@334605 c90b9560-bf6c-de11-be94-00142212c4b1
2014-08-26 14:28:17 +00:00
Chris Wright
99cec05cd4
Reworded array_rand so that reader is not addressed as "you", and incorporated edit suggested by anonymous 35207
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@332157 c90b9560-bf6c-de11-be94-00142212c4b1
2013-11-18 18:11:43 +00:00
Nikita Popov
3ce14fde5c
Normalize parameter names of array functions
...
Normalizing parameter names in docs first to later update arginfos from that.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@331477 c90b9560-bf6c-de11-be94-00142212c4b1
2013-09-24 13:06:51 +00:00
Peter Cowburn
315b44a819
Typo fix (closes doc #53193 )
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@304976 c90b9560-bf6c-de11-be94-00142212c4b1
2010-10-28 14:52:00 +00:00
Philip Olson
380c441c88
Clarified (in the description) that entry keys are returned. Closes PHP bug #52247
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@302055 c90b9560-bf6c-de11-be94-00142212c4b1
2010-08-10 01:31:30 +00:00
Daniel Egeberg
fb70264f42
Clarified the parameter's requirements.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@298761 c90b9560-bf6c-de11-be94-00142212c4b1
2010-04-29 08:33:49 +00:00
Daniel Egeberg
96c9d88bad
Converted to utf-8
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@297028 c90b9560-bf6c-de11-be94-00142212c4b1
2010-03-28 22:10:10 +00:00
Jakub Vrana
201dc3748c
Prefer <initializer> before "defaults to"
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@291313 c90b9560-bf6c-de11-be94-00142212c4b1
2009-11-25 14:49:47 +00:00
Torben Wilson
af4410a7e1
Normalized the sgml-default-dtd-file local-variable line for those
...
still using this, after discussion on the phpdoc list.
From now on, manual.ced will need to be found at ~/.phpdoc/manual.ced.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@288721 c90b9560-bf6c-de11-be94-00142212c4b1
2009-09-25 07:04:39 +00:00
Nilgün Belma Bugüner
876c81c602
fixed properties
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@283800 c90b9560-bf6c-de11-be94-00142212c4b1
2009-07-11 06:30:45 +00:00
Etienne Kneuss
28a4ad2460
Document #48224 and put randomseed in the changelog
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@280285 c90b9560-bf6c-de11-be94-00142212c4b1
2009-05-10 17:55:00 +00:00
Jakub Vrana
5730e7a2fa
Initializers - part 5
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@273648 c90b9560-bf6c-de11-be94-00142212c4b1
2009-01-16 16:14:26 +00:00
Mehdi Achour
6b20633e2a
Switch to new doc style
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@249414 c90b9560-bf6c-de11-be94-00142212c4b1
2007-12-30 11:35:36 +00:00
Hannes Magnusson
c030e2adf7
Upgrade to DocBook5:
...
- All id attributes are now xml:id
- Add docbook namespace to all root elements
- Replace <ulink /> with <link xlink:href />
- Minor markup fixes here and there
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@238160 c90b9560-bf6c-de11-be94-00142212c4b1
2007-06-20 22:25:43 +00:00
Hannes Magnusson
c3bc936236
WS, preparation for the new doc style...
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@222577 c90b9560-bf6c-de11-be94-00142212c4b1
2006-10-31 11:24:02 +00:00
Mehdi Achour
27960e632c
Merry XHTML and CS compliant christmas all \!
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@146503 c90b9560-bf6c-de11-be94-00142212c4b1
2003-12-15 16:55:22 +00:00
Heilig (Cece) Szabolcs
23396d4d4e
applying PEAR coding standards on examples
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@138081 c90b9560-bf6c-de11-be94-00142212c4b1
2003-08-17 12:21:03 +00:00
Philip Olson
56ae60d50d
Added see also's.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@135952 c90b9560-bf6c-de11-be94-00142212c4b1
2003-07-25 16:38:56 +00:00
Philip Olson
9fd7018715
Implement ¬e.randomseed; which states that random number generation is
...
automatic as of PHP 4.2.0
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@129466 c90b9560-bf6c-de11-be94-00142212c4b1
2003-05-30 19:48:38 +00:00
Philip Olson
bd220a42f3
Random seed is automatic as of PHP 4.2.0, and added php tags.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@129430 c90b9560-bf6c-de11-be94-00142212c4b1
2003-05-30 17:44:31 +00:00
Adrian Jurjica
2f7966f92e
no message
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@81901 c90b9560-bf6c-de11-be94-00142212c4b1
2002-05-12 08:19:28 +00:00
Adrian Jurjica
de71bf7038
Translation of array functions.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@81898 c90b9560-bf6c-de11-be94-00142212c4b1
2002-05-12 08:10:34 +00:00
Hartmut Holzgraefe
5b9fc29465
revision tags added
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@78496 c90b9560-bf6c-de11-be94-00142212c4b1
2002-04-17 06:45:35 +00:00
Hartmut Holzgraefe
a4b6d72ad3
banana-split
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@78202 c90b9560-bf6c-de11-be94-00142212c4b1
2002-04-15 00:12:54 +00:00