Url parameters cannot have numeric keys

Url parameters cannot have numeric keys

by Mary Cooch -
Number of replies: 11
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
I broke my Moodle 2! Not to worry- I'll just get another onesmile - but -
I wanted to add the flickr repository - so I followed the instructions to get myself a key, entered it - Moodle told me it had saved it ok -I saw it in the list but with its eye closed -so I opened its eye -and I got the message Coding error detected, it must be fixed by a programmer: Url parameters can not have numeric keys!
And now I can't get back into my Moodle. Where did I go wrong?
Average of ratings: -
In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Actually, I think Petr Skoda broke your Moodle 2.0, but he will probably fix it again soon.
In reply to Tim Hunt

Re: Url parameters cannot have numeric keys

by Petr Skoda -
Picture of Core developers Picture of Documentation writers Picture of Peer reviewers Picture of Plugin developers
Did I? I was the one who actually implemented new url validation that detects various coding problems introduced during the conversion to new url framework wink

Please turn on debug mode in your moodle and file the issue into tracker together with the stack trace, thanks.
In reply to Petr Skoda

Re: Url parameters cannot have numeric keys

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
smile Unfortunately I can't turn on debug mode as I can't log in! When I log in I get the above message!
In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Debugging explains how to force debugging on in config.php or directly in the DB.
Average of ratings: Useful (2)
In reply to Tim Hunt

Re: Url parameters cannot have numeric keys

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
ok -it's all under control wink I'll let you know!
In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
Well - with the help of a Moodle VIP (who may be named if He wishes) I got my Moodle 2 pretty much back and am 95% of the way to having my flickr repository but when I added the key and secret I got this:
You should really redirect before you start page output

* line 621 of /lib/outputrenderers.php: call to debugging()
* line 2541 of /lib/weblib.php: call to core_renderer->redirect_message()
* line 105 of /admin/repository.php: call to redirect()
..which I ignored! Then when I'd entered my callback url and tried to get an image from flickr from the tinymce I got the load of stuff I will add as a txt file and which also means nothing except that I can't get to flickr..

In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by Anthony Borrow -
Picture of Core developers Picture of Plugin developers Picture of Testers
Mary - I don't know about VIP but feel free to mention my name anytime something I do works. If it doesn't work, then you can use an alias wink Now that your site is reasonably functional, feel free to turn off debugging. Peace - Anthony
In reply to Anthony Borrow

Re: Url parameters cannot have numeric keys

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators
It was him! He helped me!big grinbig grin
In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by Julian Ridden -
Anthony is very much a VIP and should always be treated as such ;).

In reply to Mary Cooch

Re: Url parameters cannot have numeric keys

by mohamed alsharaf -
I have the same error message. After debugging the code, the code breaks at line 1141, file lib/navigationlib.php

if (!empty($editabletypes)) {
$usernode->add(get_string('repositories', 'repository'), new moodle_url('/repository/manage_instances.php', array('contextid', $contexts->user->id)));
}

I have replaced the second parameter of moodle_url from array('contextid', $contexts->user->id) to array('contextid'=> $contexts->user->id)

thats worked for me
Average of ratings: Useful (1)