encodeURIComponent(): Sometimes when you ask for help people are complete jerks
by Sue
Like today!
I was asked about URL encoding today in case we have slashes in the User IDs we are passing, which who knows on this project considering the other team is not getting us real UIDs to work with… Whole other diff bitchfest there which may end up being called “Fake Agile projects.”
Dave linked me to this jQuery URLencoding plugin and asked if it was decent. I said that I was unsure. Honestly I have never encoded URLs in javascript and did not know it was BUILT IN to the language. I asked the iDev chatroom what they thought and got a tag team of why wouldn’t you use “decodeURIComponent()“.
var url="http://mysite.com?name=stfu&snarkyopinion=do/not/want"; document.write(encodeURIComponent(url)); //gives me: //http%3A%2F%2Fmysite.com%3Fname%3Dstfu%26snarkyopinion%3Ddo%2Fnot%2Fwant
Why wouldn’t I use it? Cause I didn’t know it existed. I’m self taught and trying to get my comp sci masters NOW. There is a lot of things I DON’T KNOW. Why do people have to be dicks about it?
Like for instance I won’t to your face tell you that your use of CSS is fucking criminal, you architect things assbackwards and you’re 2 positions above me. You win, you knew about encodeURIcomponent before me.
Monday. Hate people.