Giter Club home page Giter Club logo

Comments (8)

agentgt avatar agentgt commented on June 2, 2024

The work around I did:

            var data = {};
            $.each(r.params, function(n, v) {
                data[n] = decodeURIComponent(v);
            });

from davis.js.

olivernn avatar olivernn commented on June 2, 2024

I think this could be due to the way that forms are serialised with jQuery, I'll take a closer look though because I thought this was being handled. I think you should get your params in a non-urlencoded form though so this does sound like a bug.

from davis.js.

olivernn avatar olivernn commented on June 2, 2024

Fixed in the latest release, 0.9.0.

from davis.js.

mschulkind avatar mschulkind commented on June 2, 2024

I'm on 0.9.0, but I'm still having this problem with spaces. decodeURIComponent() will not decode spaces that are encoded as '+' and a handful of other things. Do spaces work for you?

from davis.js.

olivernn avatar olivernn commented on June 2, 2024

Ah, sorry this isn't working for you. I'll take a look and see if I can get this resolved once and for all. Is it just the spaces as pluses that you are having problems with? To help me fix this could you give me an example of the link/form paths that causing the issue.

from davis.js.

mschulkind avatar mschulkind commented on June 2, 2024

It's normal GET with a single type="text" name="q" parameter. I think more characters maybe be a problem, but I'm no expert, so this is how I solved it for now:

query = URI(@raw.fullPath).query(true).q

This is using the URI.js library, so I didn't have to worry about what else needs handling.

from davis.js.

olivernn avatar olivernn commented on June 2, 2024

Ok cool, I'll take a look and get a better fix out for this.

from davis.js.

olivernn avatar olivernn commented on June 2, 2024

Fixed in 0.9.1 - sorry for the delay!

from davis.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.