Pull out values from multidimensional associative array
-
This is a bit embarrassing but arrays have always given me a run for my money.
I’m creating a plugin where I will give the user the option to select the interval they want a certain feature within my plugin to run.
So I’m pulling all cron schedules currently defined using: wp_get_schedules();
https://codex.www.ads-software.com/Function_Reference/wp_get_schedules
Then i’m doing this:$active_cron_schedules = wp_get_schedules(); print_r(Array_values($active_cron_schedules)); foreach ($active_cron_schedules as $key => $value) { echo $key; }
currently it outputs the
hourly
twicedaily
daily
my_cron
it’s not going deep enough, I want to get the “display” so it shows the “nice name” of the schedule.Help is appreciated, thank you.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Pull out values from multidimensional associative array’ is closed to new replies.