On Tue, Oct 7, 2014 at 9:05 AM, Mathias Grimm <mathiasgr...@gmail.com> wrote:
> Hi, > I would like to suggest something for php like a class I am using > > https://github.com/mathiasgrimm/arraypath > > The reason is to access arrays like this: > > $idx3 = ArrayPath::get('idx1/idx2/idx3', $_POST, 'myDefaultValue'); > > > Regards, > Mathias > Hi Mathias, The new null coalesce operator in PHP 7 achieves what you're looking for here. See https://wiki.php.net/rfc/isset_ternary Best regards, --Matthew