views:

52

answers:

1

First of all, I'd consider myself a very beginner in services development so pardon my ignorance here... I've created the rss syndication feed service (rest) in wcf and have problems with the request parameter values character. I need to pass the name as the parameter which contains the characters from the ISO 8859-2..... the request looks similar to this:

http://mojserver/feeder/service.svc/getFeed?name=šimko

but the server doesn't get the characters ok, the special characters are garbled. What am I supposed to change in order to get it running? IIS? Service?

service contract:

[ServiceContract]
[ServiceKnownType(typeof(Rss20FeedFormatter))]
   public interface IFeeder
{
[OperationContract]
[WebGet(UriTemplate = "GetFeed?name={name}&days={day}")]
   Rss20FeedFormatter CreateFeed(string name, string day); 
}

class itself

public class CustomFeed : IFeeder
{
   public Rss20FeedFormatter CreateFeed(string name, string den)
   { 
      // Create a new Syndication Feed.
      SyndicationFeed feed = new SyndicationFeed("Report", "Data", null);
A: 

You need to percent-encode any character that is not an unreserved character.

Jeremy Stein