jasonstairs Posted June 29, 2007 Share Posted June 29, 2007 Hello, I see that there is an <a href="http://us.php.net/manual/en/function.array-change-key-case.php">array_change_key_case()</a> function, but is there one to change the case of an array value, ie., array_change_value_case()? Link to comment https://forums.phpfreaks.com/topic/57759-solved-array_change_value_case/ Share on other sites More sharing options...
akitchin Posted June 29, 2007 Share Posted June 29, 2007 yes, it's called array_map(): array_map('strtoupper', $array); you'll need to make a recursion to make sure it hits every level, but check the comments on the function in the manual - someone's already done that for you. Link to comment https://forums.phpfreaks.com/topic/57759-solved-array_change_value_case/#findComment-286022 Share on other sites More sharing options...
jasonstairs Posted June 29, 2007 Author Share Posted June 29, 2007 Thank you, that did the job! Link to comment https://forums.phpfreaks.com/topic/57759-solved-array_change_value_case/#findComment-286126 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.