How can I write this code in one php operator?
$menu = theme('nice_menu', 1, 10, 'down');
print $menu['content'];
Something like this:
print theme('nice_menu', 1, 10, 'down')['content'];
Not on a production version of PHP. This has been added to the trunk for the next version (Currently called 5.3.99DEV, but it's unsure if it'll be 5.4 or 6.0 or what)... It's called Array Dereferencing. See the RFP...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With