title: How to convert html text to raw text in code behind in other words strip text from html
body: <p>Using a rss feed(syndicationfeed) I have some encoded text where normally in the view I can just say @Html.Raw(feed.summary) where feed.summary is some html with text in it, and it will display the text without all the html code. However for some reason, this is not working. It's breaking my view, no crashing its just not displaying anything. So I was wondering if there is a way to do this in code behind that way the text will all ready be stipped and I don't have to use Html.Raw() in my view. Any advice is appreciated.</p>
  
  <pre><code> @Html.Raw(feed.RssShortSummary) 
    //This doesn't work, it messes all my styling up and simply doesn't even display the text.
  </code></pre>
  
  <p>In Code behind: (I've tried MvcHtmlString.Create()) but still returns the html code and not the text I need from it.</p>
  
  <pre><code>   MvcHtmlString.Create(summary);
  </code></pre>
  
  <p>So if I have:</p>
  
  <pre><code> &lt;p&gt;Here is some text&lt;/p&gt; 
  </code></pre>
  
  <p>Html.Raw() will return "Here is some text" but this messes my view for some reason. I've tried MvcHtmlString.Create but it is still returning to me:</p>
  
  <pre><code>&lt;p&gt;Here is some text&lt;/p&gt; //returning all the html instead just "Here is some text"
  </code></pre>
  
  <p>In code c# I tried: </p>
  
  <pre><code>  var x = MvcHtmlString.Create(rssItem.RssSummary);
  </code></pre>
  
  <p>where for example rssItem.RssSummary = </p>
  
  <pre><code>  &lt;p&gt;Here is some text&lt;/p&gt;
  </code></pre>
  
  <p>x is still generating: </p>
  
  <pre><code>     &lt;p&gt;Here is some text&lt;/p&gt; 
  </code></pre>