Copied to clipboard

Flag this post as spam?

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


  • Steve 4 posts 24 karma points
    Oct 12, 2010 @ 16:47
    Steve
    0

    MasterPages and visual studio

    Hi

    I'm new to umbraco, about 30 mins old in fact!

    I've downloaded the vs 2010 project template and having a go at creating a site and already stuck!!

    I've created a masterpage, used the default.master as the MasterPageFile, its in the masterpages directory, I build the site, all is good and everything gets copied to the umbraco file structure as I would expect.

    However when I go into the site via the admin interface I cannot see the masterpage I just created??

    I can however see the style and xslt file that I created?

    I am using a code behind file for the masterpage, but the way i understand it, thats fine?

    Thx

    Steve

  • Steve 4 posts 24 karma points
    Oct 12, 2010 @ 16:51
    Steve
    0

    I have just discovered that if I go into the admin interface, click create new on the templates directory, give it the same name as my masterpage it picks up the file from the file system.

    Is that the expected behaviour?

    Thx

  • Lee Kelleher 4026 posts 15836 karma points MVP 13x admin c-trib
    Oct 12, 2010 @ 17:13
    Lee Kelleher
    0

    Hi Steve,

    Templates (ASP.NET Master Pages) need to be created in the Umbraco back-office directly - as they are referenced in the database (used for document-types).

    Once the template has been created - you can edit it in Visual Studio, no problem.

    Cheers, Lee.

  • Steve 4 posts 24 karma points
    Oct 12, 2010 @ 17:15
    Steve
    0

    Thx Lee, much appreciated.

  • Richard Soeteman 4046 posts 12899 karma points MVP 2x
    Oct 12, 2010 @ 17:18
    Richard Soeteman
    0

    Hi Steve,

    Yes this is expected behaviour. There is a relation between document types and templates that is stored in the database. So when you create a template on disk the database isn't modified and that's why you get that error. Most people create all their stuff in Umbraco btw.

    Not bad for a 30 minute user to figure it out though...

    Cheers,

    Richard

Please Sign in or register to post replies

Write your reply to:

Draft