How to add behavoirs to asp.net mvc 2 action result output <p>Lets say I have two controllers and two actions.</p> <p>Controller - > AController Action -> MethodA()</p> <p>.</p> <p>Controller - > BController Action -> MethodB()</p> <p>Both of these return xml data by a View(typedObject).</p> <p>I want to add base 64 encoding before returning this output to the client. On MethodA and MethodB. And there might be some other methods that should be included in this encoding aswell.</p> <p>Would there be any good way of accomplish an behavoir / treatment of the action result ?</p> <p>Would it be best to add a custom Action Result for this ?</p>