per example 8.2 on this page: https://docstore.mik.ua/orelly/webprog/pcook/ch08_10.htm#phpckbk-CHP-8-EX-2 ,
I’m not really understanding why they are using strings as the index portion of the array function here. per this page: https://www.php.net/manual/en/function.array.php , if the index vals are omitted, integers are automatically generated. my question is this:
=> why do I have to have an array like this:
array('value 1' => 'pw 1', 'value 2' => 'pw 2');
when it is much easier to write this:
array('value 1', 'value 2', 'value 3');
??? is this just part of the syntax that PHP offers and there is nothing I can do about this semi-convolution? thanks.
Adam