Welcome Guest, Not a member yet? Register   Sign In
Jquery Validation URL Problem


i got a problem with my jQuery Validation URL ... it always try to send:

GET http://www.example.com/registration/ajaxControl/?username=test 190ms

It responds (cauz the GET Query Request):

The URI you submitted has disallowed characters.

I've looked in the jquery.validate.js to locate the URL building function, but without results.

Is there any way for CI to rewrite the URLs to segments like


Thanks for your help

[eluser]Nick Husher[/eluser]
Not knowing that much about jQuery, would it be possible to pass it by POST instead of GET?

[eluser]Pascal Kriete[/eluser]
Nick is on the ball, as usual.
In the 'remote' function there is a call to $.ajax . I don't have the source in front of me, but what you need to do is add the type parameter:
    url: something,
    type: 'POST', //add this
  // ....

[eluser]Nick Husher[/eluser]
Just to be really clear, GET query strings in CodeIgniter are disallowed by default. Characters in your disallowed url characters list (in config or routes.php, IIRC) will trigger the error message you're getting. As an alternative to using POST, you can take a look at enabling query strings and enabling some creative routing:


Theme © iAndrew 2016 - Forum software by © MyBB