Search results do not load with %0A in them

<hidden> anonymous
Created: 5 years and 24 days ago

I found what appears to be a small bug in DDG. Search terms with a newline (%0A) in them load instant answer boxes:

but none of the actual results:

Newlines are sometimes in search terms when copying part of a webpage (for me, often an article title and its author) and pasting it into a new search.

Thanks! Long-time user of DDG here looking to help make it even better.

This forum has been archived

Thank you all for the many comments, questions and suggestions. Particular thanks go to user x.15a2 for constantly monitoring, replying and helping so many users here. To continue these discussions, please head over to the DuckDuckGo subreddit.

Thanks for your report!
Actually, I'm wondering how yo, technically speaking, managed to paste a "new line" (aka. %0A) into the search field. I thought that was impossible. : D Well, you learn learn something new every day, don't you? : )
posted by ScreapDK Community Leader5 years and 24 days ago Link
Erm, yes, it should be. OP, what browser are you using?
Firefox and Chromium both strip newlines out of text pasted into the search fields or any single-line input box--as they should.
posted by crazedpsyc 5 years and 24 days ago Link
I'm using Firefox on Ubuntu. This most often occurs when using the Vimperator extension -- pressing "p" opens the address (or search terms) from the clipboard. Since DDG is my default, any terms (and new lines) are searched in DDG, causing the problem.

Of course, this is a fairly isolated case, but anyone searching for something like "what does %0A mean?" would have the same problem.
posted by <hidden> • 5 years and 24 days ago Link
This comment has been removed for violation of our forum rules.
posted by <hidden> • 5 years and 24 days ago
That's because it (improperly) ignores the word 0A. Unrelated issue.
posted by crazedpsyc 5 years and 24 days ago Link
I'm about to roll a fix out for this. As a few others have said it's odd the query managed to get an encoded \n into the query. It's actually having trouble in the JS and not on the backend. Thanks for writing us about it!
posted by caine Staff5 years and 18 days ago Link
Just to play a bit more and show a small example of the kind of thing that was happening. :)

posted by caine Staff5 years and 18 days ago Link