Jump to content
Sign in to follow this  
Onno

[C#] Squad XML response type

Recommended Posts

I'm trying to write an application which will serve up Squad XML's.

It's a bit of an exercise to keep me busy and to stay up to date with my coding skills. (I'm aware of the php implementations, but I prefer .Net)

I'm trying to write it in C#. If possible, I'd like to serve up the file from a routed response (MVC4)

Would specifying "www.sarisdragons.org/squadname/xml/" be accepable as an input for the game if the response would be text/xml?

Does the game accept such a response, or does it need an actual file to download?

I also want to know how this is handled for the .PAA file.

would specifying "www.sarisdragons.org/squadname/shield/" be acceptable if the response mime type would be application/octet-stream?

Edited by Onno

Share this post


Link to post
Share on other sites

Anyone?

Maybe this should be moved to scripting instead, if this isn't getting any replies?

Share this post


Link to post
Share on other sites

I did a similar thing in Scala a while ago and I used ..../:playername/xml with text/xml as the mine type. So it definitely doesn't need a file it will take a reasonable URL, xml/ isn't an end point but I suspect it will accept it. As to the mime type I don't remember if it has to be text/xml, I used the right mime type but then play framework will use that automatically when you use an XML as the response. I wouldn't be surprised if BI doesn't even check it so I would try a hardcoded response and see if it works or not, I am about 90% confident it will.

  • Like 1

Share this post


Link to post
Share on other sites

I did a similar thing in Scala a while ago and I used ..../:playername/xml with text/xml as the mine type. So it definitely doesn't need a file it will take a reasonable URL, xml/ isn't an end point but I suspect it will accept it. As to the mime type I don't remember if it has to be text/xml, I used the right mime type but then play framework will use that automatically when you use an XML as the response. I wouldn't be surprised if BI doesn't even check it so I would try a hardcoded response and see if it works or not, I am about 90% confident it will.

 

Thank you for this answer. It was exactly the information I was looking for! :)

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×