ParseError thrown

syntax error, unexpected '$json_key' (T_VARIABLE)