Copied to clipboard

Flag this post as spam?

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


  • glob 72 posts 172 karma points
    Jun 22, 2013 @ 16:57
    glob
    0

    Can i use "Postback" in Umbraco 6.1.1 ?

    I have a website using Umbraco 4.7.2 now  I  want to upgrade it to MVC Umbraco 6 with web form user control, so....is it possible..? What is the setting in umbracosetting.config file as well as web.config?

     

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jun 23, 2013 @ 14:33
    Sebastiaan Janssen
    0

    You can just keep using Webforms, they're still there. Mvc is just an addition. The defaultRenderingEngine in umbracoSettings.config is set to WebForms by default, just keep it that way.

  • glob 72 posts 172 karma points
    Jun 24, 2013 @ 07:26
    glob
    0

    I done your settings in umbracosettings.config like defaultRenderingEngine Mvc to WebForms , but my usercontrol still not working,... Should i change template, mvc to normal for this usercontrol or not..?,

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jun 24, 2013 @ 12:28
    Sebastiaan Janssen
    0

    Yes, in order to use postback you need to have a masterpage template, postback with user controls will not work with MVC views because you need viewstate, which is not available in MVC.

  • glob 72 posts 172 karma points
    Jun 24, 2013 @ 13:42
    glob
    0

    Thanks for the clarity....

    Now one more question,

    I installed ublogsy 3 with umbraco 6.1.1 , If I changed defaultRenderingEngine Mvc To Webforms,Usercontrol works fine but i can't see mvc base template code of ublogsy 3 in cms, i can see only masterpage template code,so what is the setting for viewing the template code of mvc..?

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jun 24, 2013 @ 14:14
    Sebastiaan Janssen
    100

    I think if you create a masterpage with the same alias as the view it should work, but I'm not sure.

    Try this: go to one of the uBlogsy templates and look at the alias of the template, for example: myTemplateAlias.

    There's a file in the Views folder with the name myTemplateAlias.cshtml if you now create a masterpage in the MasterPages folder with the name myTemplateAlias.master does it work then?

    If it doesn't work you might need to switch it around: set defaultRenderEngine to Mvc, then for each masterpage create only the masterpage (so myTemplateAlias.master) and no View. So all of the uBlogsy templates will still be in the Views folder and your masterpage with the usercontrol only exists in the masterpages folder.

  • glob 72 posts 172 karma points
    Jun 25, 2013 @ 08:58
    glob
    0

    thanks, solved this problem

    now one more question if you can help.

    is it possible to have both uBlogsy3 (that requires mvc) and webfrom with a post-back in same web page? Do I have to migrate the form to mvc, or any settings can make it both work?

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jun 25, 2013 @ 10:02
    Sebastiaan Janssen
    0

    Great! Yes, you should migrate the form to MVC, it's just impossible for WebForms forms to work in an MVC view.

Please Sign in or register to post replies

Write your reply to:

Draft