Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Max McCarty 6 posts 26 karma points
    Aug 13, 2012 @ 16:43
    Max McCarty
    0

    Request page content through System.Net WebClient in asp.net MVC

    Um

    My project is running along side asp.net MVC 4.  I have a Umbraco page, which has a Rich Text editor property on the document type, that will retain a body of text with HTML.  

    Is there a way to use a System.Net.WebClient client, and request the Umbraco page from within my MVC project and have it return the content of that page's document property to the MVC controller's WebClient request?

     

    Bonus Question:

    Is there a way to setup an Umbraco macro in the template that will parse the querystring params and have place holders in the Umbraco template that the macro will replace the placeholders with the parsed out querystring params before the content is returned to the request (explained up above)?

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Aug 14, 2012 @ 08:58
    Jeroen Breuer
    0

    For the bonus question thig might help: http://our.umbraco.org/wiki/reference/templates/umbracomacro-element. You can use [@yourQueryString] to get the value from a querystring.

    Jeroen

Please Sign in or register to post replies

Write your reply to:

Draft