The place to discuss how to make 23 work in special ways with the 23 api

url decode parameters

stephenh   October 26, 2005, 04:40 PM

Hi,

I'm uploading photos+tags pretty well via /services/upload/.

However, some of my tags have spaces and what not in them, so I url encode everything on the way up.

And it doesn't look like they ever get url decoded as I'm seeing tags like "foo%2Es" and "a+space" instead of "foo's" and "a space", respectively.

Thanks.

 
Steffen Fagerström Christensen Team 23   October 28, 2005, 11:07 AM

Hey,

This behaviour should have been changed now. A note though: This bug has only been relevant when posting to the REST interface while still placing the parameters in the url query string. And my fantastic question to this: Why would you do this?


/Stc

 
stephenh   October 28, 2005, 03:12 PM

...Hm...good question.

I'm not using the URL parameters, but a multipart/form-data POST with the tags/photo/etc.

So, now that I think about it, you're right, I shouldn't have to url encode anything.

However, the behavior I noticed early on was that if I posted a photo with a tag like "a space" it ended up with 2 tags, 1 "a" and 1 "space".

My hack was to url encode, so then a "+" gets put in there.

But you're right, that is not the right way to solve it.

So...can 23 tags just not have spaces?

I suppose I could just replace all " " with "_".

 
Steffen Fagerström Christensen Team 23   October 28, 2005, 03:22 PM

Have you checked your application now? My guess is that you'll see that the problem's solved (as we're decoding the input from the url query and combining it into the post data).


/Stc

 




About 23

About 23
What is 23 and who's behind the service?
Just In
Discover the world from a different angle.
Here's a crop of the latest photos from the around the world.
Search
Search photos from users using 23
Help / Discussion
Get help or share your ideas to make 23 better
23 Blog / 23 on Twitter
Messages and observations from Team 23
Terms of use
What can 23 be used for and what isn't allowed
More services from 23
We also help people use photo sharing in their professional lives
RSS Feed
Subscribe to these photos in an RSS reader
  • Basque (ES)
  • Bulgarian (BG)
  • Chinese (CN)
  • Chinese (TW)
  • Danish (DK)
  • Dutch (NL)
  • English (US)
  • French (FR)
  • Galician (ES)
  • German (DE)
  • Italian (IT)
  • Norwegian (NO)
  • Polish (PL)
  • Portuguese (PT)
  • Russian (RU)
  • Spanish (ES)
  • Swedish (SE)

Popular photos right now