createAlbum returns string "sreate error" instead of an int AlbumID
jef
Registered Users Posts: 42 Big grins
Yes, it really says sreate. I only get this on some of my createAlbum calls, most of the time it works just fine. The ones it fails on, it fails every time. I don't see anything unusual in the parameters for those calls vs. the others.
0
Comments
..Yet it obviously seems to be a very unimportant and/or very tough-to-fix one since it hasn't been fixed for several weeks..
Along the same lines - there is also a problem with ' and " in album descriptions (if submitted through API).
You see, SM UI uses multipart form based input, but API uses simple xml post, hence the problems..
In SE I came out with workound of replacing ' with ` - lame, but better than error message..
About the ampersand issue, I removed those from my pix too. Have you played with variations like turning them into & amp ; ? Also, since it's XML you could probably encapsulate all the text as CDATA.
& amp ; - works, an & appears.
CDATA - doesn't work, the text just disappears.
& #x27 ; - doesn't work, the same "sreate error" as with a plain '.
unfortunately, nothing seems to work so far..
Just retested - both ' and " works:-)
I realized that my earlier test of CDATA was bad because the underlying tool was still escaping the anglebrackets. I re-did the test right and CDATA seems to solve all these problems. Single quote, double quote, ampersand, HTML entities, even hot links, they all go through. Yay!
Nah, probably not CDATA. I fixed it.
Don
I tried the previous version of my XML-RPC tool, without the CDATA, and confirmed that the API now handles single quotes in the title and description. However it still doesn't handle things like HTML entities and hotlinks, so I'll stick with my CDATA version which does let it handle those.