Jump to content

array key


Destramic

Recommended Posts

hey guys i have a an array and i want to know if i can call the value without having to put the array key in capitals.

 

here is my array

Array
(
    [DEVELOPEMENT_ENVIORMENT] => 1
    [MSQL_HOST] => localhost
    [MYSQL_USERNAME] => root
    [MYSQL_PASSWORD] => test
    [MYSQL_DABASE_NAME] => test
)

 

can i call the array like $array['mysql_host']Array

(

    [DEVELOPEMENT_ENVIORMENT] => 1

    [MSQL_HOST] => localhost

    [MYSQL_USERNAME] => root

    [MYSQL_PASSWORD] => n0real1ty

    [MYSQL_DABASE_NAME] => test

)

 

can i call the array like $array['mysql_host'] instead of $array['MYSQL_HOST'] whichout renaming the array key

 

if anyone could help please...thank you

Link to comment
https://forums.phpfreaks.com/topic/234429-array-key/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.