Copied to clipboard

Flag this post as spam?

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


  • Maxim 50 posts 69 karma points
    May 27, 2014 @ 18:41
    Maxim
    0

    Need some help :)

    hello,

    I'm pretty new to umbraco and recently set op a website, did the lay-out and got now 2 pages. But is it possible to make a log in for people and that they can order products? Not paying them online but only order them and lets say they can go get the order in the store. It's for a school project and i would like to have some information/help. 

    greetings

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 27, 2014 @ 18:51
    Steve Morgan
    0

    For your first task you need a package - try UCommerce (you can install packages from the Developer menu).

    To secure pages you just click the right hand button on the pages you wish to change and click the Public Access link - let us know how you get on!

     

    Steve

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 27, 2014 @ 19:17
    Steve Morgan
    0

    Just a bit more to help with securing pages.. first create go to Developer and create a Partial View Macro File called "Login" - select "Login" as the snippet. This is the code that will create your login page. Now we need a page to hold this on - so create a new document type called LoginPage and in the corresponding template add a tag:

    @Umbraco.RenderMacro("SecurePage")

    Create a page called "Login" in the content section using this document type and then go to your page you wish to secure - right click and select Public Access. Set a single user login (this will create a "Member" user) and then select your new Login page in the Login Page section and your home page in the error page option and Update.

    That should give you what you need. 

  • Maxim 50 posts 69 karma points
    May 27, 2014 @ 19:42
    Maxim
    0

    How can i install, i mean where do i need to put all the files?

     

  • Maxim 50 posts 69 karma points
    May 27, 2014 @ 20:44
    Maxim
    0

    steve, i just made my document type, template for it and putted in my content but now it says: Content saved: Remember to publish to make changes visible. And I published everything. And how can i make sure people can register for it?
    also where can i change where the login textbox, label and password textbox, label is standing? cus now i doens't look nice tho ;p

     Thanks for your help and your time!

  • Maxim 50 posts 69 karma points
    May 27, 2014 @ 21:25
    Maxim
    0

    I found in the macro also to register but now i got another and very annoying problem. Because i was abit sloppy (i don't know if its the correct word) I have 3 templates that says registerpage, yet i only made 1 so far i know. But i can't delete or update 1 of them. It keeps getting me errors. 

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 28, 2014 @ 12:50
    Steve Morgan
    0

    Hi,

    Sounds like you may have found a bug.. can you post a screenshot, perhaps someone here can help. It's hard when we can't see what you're looking at and the error. 

     

    As for uCommerce - there is a free version, did you see that?

     

    Steve

  • Maxim 50 posts 69 karma points
    May 28, 2014 @ 13:14
    Maxim
    0

    Well the bug was that I allready had a preview open. And yes i found the uCommerce. Now i still need my register page. is it also like the macro with login?

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 28, 2014 @ 13:39
    Steve Morgan
    0

    I haven't done this before.. so I just did a quick test!  Yes - your guess is correct...

    Create a new Partial view called "register" and select the snippet "register member" then create a document type "Register" with a matching template and like you did before add this Parial View Macro on that template.

    Then create the page in the content section - perhaps call it "register" and see what you get when you load this page!  

    You might now find that you need to modify the settings on your protected page to allow a member group rather than a single member (as my quick test used) - this gives you a small problem that you need to have new members become a member of htis group (which will give them access to your secured pages). I suspect you're going to need to modify the default Razor code in your Partial Macro Code to do this...  are you happy with code? If not post this as a seperate question and I'm sure someone here will help (I would look at it but I've got some work to do today).

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 28, 2014 @ 13:40
    Steve Morgan
    0

    Having read back my last post - I'm assuming that you'd want new members to automatically have access to the protected pages, actually perhaps you'd need people to review the member before allowing this so this might be fine as it is? Depends what your goals are. 

  • Maxim 50 posts 69 karma points
    May 28, 2014 @ 18:31
    Maxim
    0

    Well, if i want to change my master template for my register page it gives an error. Also i got duplicate templates, like 3x register page and i can't delete 1 of them.

  • Maxim 50 posts 69 karma points
    May 28, 2014 @ 18:33
    Maxim
    0

    and this is what i get when i want to remove 1

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 28, 2014 @ 18:52
    Steve Morgan
    0

    Can you screen shot what the left hand menu / tree looks like? 

  • Maxim 50 posts 69 karma points
    May 28, 2014 @ 20:31
    Maxim
    0

    The file registratie has to come under master. All the Registerpages are wrong

     

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 29, 2014 @ 11:40
    Steve Morgan
    0

    This is a bug. You've managed to create a duplicate template (e.g. the template aliases are duplicated RegisterPage). 

    I've managed to recreate this so I can report it as a bug but I've also found a simple workaround so you can tidy up your copy of Umbraco. Go to one of the RegisterPage templates and change the Name AND the Alias to RegisterPage2 and save. You can then delete this normally.

    I hope that helps. 

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 29, 2014 @ 12:22
    Steve Morgan
    0

    Thanks for the screenshots - I've created a bug report. All helps improve Umbraco. 

    http://issues.umbraco.org/issue/U4-5014

     

  • Maxim 50 posts 69 karma points
    May 29, 2014 @ 16:52
    Maxim
    0

    Hi steve,

    How could move my navigation buttons?

    Cus when I have 3 buttons they are perfectly placed next to each other. When I add 1 more then they get in 2 rows and not even good under each other.

    Here you have a printscreen:

  • Steve Morgan 1349 posts 4458 karma points c-trib
    May 29, 2014 @ 17:36
    Steve Morgan
    0

    By the looks of that screen shot it looks like you're using the tutorial I wrote for creating a basic site http://our.umbraco.org/documentation/Using-Umbraco/Creating-Basic-Site/ - nice to see!

    Your issue is the CSS for this template is kind of hardcoded for three menu items - wish I'd spotted that when I chose that template example to write the tutorial.

    This needs some CSS work (in other words you need to change the style.css file you copied to the Css folder).

    I'd recommend finding a good tutorial on how to use Dev tools in Chrome / Firefox and anaylsing the CSS elements on the <nav> <ul> and <li> elements..

    HINT: the nav a {} rules on line 171 have a width of 27% - four lots of 27% > 100%.  A quick change would be to modify this to be min-width: 18%; and increase the width of the nav (line 218) to 58%. 

    You'll have to play with these settings though to ensure this doesn't break on other resolutions and still looks "right" (e.g. try shrinking and growing the browser). TBH I don't like the way they've done this nav - perhaps you need to replace this. 

  • Maxim 50 posts 69 karma points
    May 29, 2014 @ 17:47
    Maxim
    0

    Yes i used your tutorial ;) hehe.
    Well, tomorrow i will look further but now i found the nav in the code. I'll tell you if it worked or not. :)
    Thank you for your time and help tho :)  

  • Maxim 50 posts 69 karma points
    May 31, 2014 @ 17:02
    Maxim
    0

    Hello, I changed those thing you say, yet i see no difference. I changed it from 27% to -> 20% and on line 218 to 58%. Nothing even happens when i change these.

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 01, 2014 @ 11:25
    Steve Morgan
    0

    This is a CSS question not really an Umbraco question - it's going to be almost impossible to fix / help you with via this forum but here are a few pointers to help you fix this yourself.

    The template creates a responsive page - this means that different CSS rules apply depending on the size of your browser window. This makes it impossible to see what you're seeing but if you look in the CSS sheet you'll see lines like:

    @media only screen and (min-width: 480px) {

    This means that rules between these braces { } only apply above browser widths of 480p - I suspect the lines I asked you to change are not relevant to the view you have which is why it's not changed anything. 

    I'd recommend you learn how to use Chrome's dev tools and really get to grips with CSS - there are plenty of Youtube tutorials, this is the first one I found. https://www.youtube.com/watch?v=Z3HGJsNLQ1E using Chrome tools you can "inspect" the nav and ul, li elements and see which rules are applied and even change them to preview what it would look like before making changes to your CSS file.

    If you're really stuck with understanding something in CSS then ask a question in a forum such as http://stackoverflow.com/questions/tagged/css - note that you're using this template and what you're trying to achieve and ideally screen shot or (better) provide a link. 

     

     

  • Maxim 50 posts 69 karma points
    Jun 01, 2014 @ 15:50
    Maxim
    0

    Hi steve,

    I found it :D. It wasn't hard but just some searching ;p. I really appreciate your help! here is a look how it looks now:
     

    Yet, when users log on they aren't logged on. Like you can log on but the website doesn't cache it or something. Like i want a session that the browser can hold for like 1 hour. Also i want that you can see if you are logged on or not. I've done some searching but i still didn't find it.
     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 01, 2014 @ 16:08
    Steve Morgan
    0

    There is a Partial View Macro snippet called "Login Status" that will serve you. 

    Add a new partial view macro called "Login Status" - select this snippet and then include it in the footer of your master template (or whereever you like). You can add a bit of logic so that if the user isn't logged in it shows a link. e.g:

    @inherits Umbraco.Web.Macros.PartialViewMacroPage
    
    @using System.Web.Mvc.Html
    @using ClientDependency.Core.Mvc
    @using Umbraco.Web
    @using Umbraco.Web.Models
    @using Umbraco.Web.Controllers
    
    @{
        var loginStatusModel = Members.GetCurrentLoginStatus();
    
        Html.EnableClientValidation();
        Html.EnableUnobtrusiveJavaScript();
        Html.RequiresJs("/umbraco_client/ui/jquery.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.min.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.unobtrusive.min.js");
    
        var logoutModel = new PostRedirectModel();
    
        @*
            Here you can specify a redirect URL for after logging out, by default umbraco will simply
            redirect to the current page. Example to redirect to the home page:
    
            logoutModel.RedirectUrl = "/"; 
        *@
    }
    
    @* NOTE: This RenderJsHere code should be put on your main template page where the rest of your script tags are placed *@
    @Html.RenderJsHere()
    
    @if (loginStatusModel.IsLoggedIn)
    {
        <p>You are currently logged in as @loginStatusModel.Name</p>
    
        using (Html.BeginUmbracoForm<UmbLoginStatusController>("HandleLogout"))
        {
             <fieldset>
                 <legend>Logout</legend>
                 <button>Logout</button>
             </fieldset>
    
            @Html.HiddenFor(m => logoutModel.RedirectUrl)
        }
    } else
    {
        <p><a href="/login">Login here</a></p>
    }

    As for member timeouts I think you just need to change the web.config line 213 to 60 mins:

       <membership defaultProvider="UmbracoMembershipProvider" userIsOnlineTimeWindow="60">

     

  • Maxim 50 posts 69 karma points
    Jun 01, 2014 @ 16:18
    Maxim
    0

    hi steve,

    I was able to create the macro and i changed it abit. Yet i don't see it on my website. I putted in my footer and I didn't see something. Same for the header. membertimeouts works tho.

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 01, 2014 @ 16:24
    Steve Morgan
    0

    I have just noticed something in this which I'm unsure how to fix. If you visit the site and you're not logged in and you hit a protected page it correctly redirects you to the login page. However when you successfully login it redirects you to the login page.. not the page you wanted. Do you get the same thing - I'm wondering if there is some work to do in the razor macros or if this is a bug. 

     

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 02, 2014 @ 14:33
    Steve Morgan
    0

    Maxim it sounds like you haven't included the @Umbraco.RenderMacro("LoginStatus") line - this is the footer section of my Master template and it works?!

     

       @RenderBody()
    
        <div id="footer-container">
            <footer class="wrapper">
                <h3>@Umbraco.Field("footerText", recursive: true)</h3>
                @Umbraco.RenderMacro("LoginStatus")
            </footer>
    
        </div>
    
    </body>
    </html>
  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 02, 2014 @ 14:36
    Steve Morgan
    0

    I've had a look at the issues on the login snippet (e.g. the user is not redirected to the page they requested that is protected... have a try of replacing your login razor code with this. You need to change this line var loginNodeID = 1056; to be your login page node ID (get this by looking in the content properties tab in for the login "page". 

     @inherits Umbraco.Web.Macros.PartialViewMacroPage
    
    @using System.Web.Mvc.Html
    @using ClientDependency.Core.Mvc
    @using Umbraco.Web
    @using Umbraco.Web.Models
    @using Umbraco.Web.Controllers
    
    
    @{
        // You have to set the login node ID otherwise you'll have an infinite loop if someone hits the login page first
        var loginNodeID = 1056;
        var loginModel = new LoginModel();
        var loginStatusModel = Members.GetCurrentLoginStatus();
    
        Html.EnableClientValidation();
        Html.EnableUnobtrusiveJavaScript();
        Html.RequiresJs("/umbraco_client/ui/jquery.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.min.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.unobtrusive.min.js");
    }
    
    @* NOTE: This RenderJsHere code should be put on your main template page where the rest of your script tags are placed *@
    @Html.RenderJsHere()
    
    @{
        var checkUrl = HttpContext.Current.Request.Url.AbsolutePath.ToString();
    
        // add a trailing / if there isn't one (you can access http://mydomain.com/login or http://mydomain.com/login/
        if (@checkUrl[checkUrl.Length -1] != '/') {
            checkUrl = checkUrl + "/";
        }
    
        @* if we don't have a session variable and have a request URL then store it *@
        @* we have to store it because if user tries an incorrect login then Current.Request.Url will show /umbraco/RenderMvc *@
        if (HttpContext.Current.Request.Url != null && HttpContext.Current.Request.Url.AbsolutePath.ToString() != "/umbraco/RenderMvc" && HttpContext.Current.Session["redirectURL"] == null) {
            if (checkUrl !=  @Umbraco.Content(loginNodeID).Url) {
                HttpContext.Current.Session["redirectURL"] = HttpContext.Current.Request.Url.ToString();
            }
        }
    
        if (loginStatusModel.IsLoggedIn)
        {
            var redirectUrl = (string)HttpContext.Current.Session["redirectURL"];
    
            var currentUrl = HttpContext.Current.Request.Url.ToString();
            if (HttpContext.Current.Session["redirectURL"] != null) {
                // clear the session variable for future logins
                HttpContext.Current.Session["redirectURL"] = null;
                HttpContext.Current.Response.Redirect(redirectUrl);
            }
            else {
                // Nothing in the session so we will go home 
                HttpContext.Current.Response.Redirect("/");
            }
        }
    
    
        using (Html.BeginUmbracoForm<UmbLoginController>("HandleLogin"))
        {
            <fieldset>
                <legend>Login</legend>
    
                @Html.ValidationSummary("loginModel", true)
    
                @Html.LabelFor(m => loginModel.Username)
                @Html.TextBoxFor(m => loginModel.Username)
                @Html.ValidationMessageFor(m => loginModel.Username)
                <br />
    
                @Html.LabelFor(m => loginModel.Password)
                @Html.PasswordFor(m => loginModel.Password)
                @Html.ValidationMessageFor(m => loginModel.Password)
                <br />
    
                <button>Login</button>
            </fieldset>  
        }
    }
  • Maxim 50 posts 69 karma points
    Jun 02, 2014 @ 18:23
    Maxim
    0

    Hello,

    I have the same like you and still can't see it on my site.

    @RenderBody()
                    <div id="footer-container">
            <footer class="wrapper">
                <h3>@Umbraco.Field("footerText", recursive: true)</h3>
                @Umbraco.RenderMacro("LoginStatus")
            </footer>
        </div>
    
    </body>
    </html>

    could you show me how it looks on the website of yours?

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 02, 2014 @ 19:08
    Steve Morgan
    0

  • Maxim 50 posts 69 karma points
    Jun 02, 2014 @ 19:12
    Maxim
    0

    i don't get that in my footer tho :/

  • Maxim 50 posts 69 karma points
    Jun 02, 2014 @ 20:11
    Maxim
    0

    do you see any mistakes in the code?

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 02, 2014 @ 20:54
    Steve Morgan
    0

    Not in what you've done in the template but you need to look at the Macro. Go to the developer section and check that your Macro "LoginStatus" references you partial macro view "Login Status".

     

    If that's correct then check the Partial view macro..  around line 30 try adding the line <p>This is a test</p>:

    @* NOTE: This RenderJsHere code should be put on your main template page where the rest of your script tags are placed *@
    @Html.RenderJsHere()
    
    <p>This is a test</p>
    
    @if (loginStatusModel.IsLoggedIn)
    {

    You should then see the text "this is a test" in the footer. If you don't something is wrong in the steps above or with the Razor in the macro.

  • Maxim 50 posts 69 karma points
    Jun 03, 2014 @ 14:47
    Maxim
    0

    Hi,

    Still don't see the text this is a test. here you have a screenshot of my code in the macro.

    Also, i want to add when you log in on the site you get redirected to a webshop. I want to use Ucommerce and I installed the package. But i don't get it in my left border. I read somewhere that you can't use it with SQL CE. Can I change from SQL CE to something else?
    Also i want the template be light blue with dark blue instead of light orange with dark orange.

    Maxim 

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 03, 2014 @ 15:13
    Steve Morgan
    0

    Hi Maxim,

    You're asking lots of questions in a single post which is making it hard to help! 

    1) Nothing output in Login Status

    The screen shot doesn't show all the code - can you copy and paste it into the forum (you can use the style Preformatted) - as you have it there it will ONLY output something if you're logged in as a member (not logged into the Umbraco backend - these are different things). 

    2) Redirect to webshop 

    Change your Login Razor Partial Macro View code to:

    @inherits Umbraco.Web.Macros.PartialViewMacroPage
    
    @using System.Web.Mvc.Html
    @using ClientDependency.Core.Mvc
    @using Umbraco.Web
    @using Umbraco.Web.Models
    @using Umbraco.Web.Controllers
    
    
    @{
        // You have to set the login node ID otherwise you'll have an infinite loop if someone hits the login page first
        var loginNodeID = 1056;
        var loginModel = new LoginModel();
        var loginStatusModel = Members.GetCurrentLoginStatus();
    
        Html.EnableClientValidation();
        Html.EnableUnobtrusiveJavaScript();
        Html.RequiresJs("/umbraco_client/ui/jquery.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.min.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.unobtrusive.min.js");
    }
    
    @* NOTE: This RenderJsHere code should be put on your main template page where the rest of your script tags are placed *@
    @Html.RenderJsHere()
    
    @{
        if (loginStatusModel.IsLoggedIn)
        {
            HttpContext.Current.Response.Redirect("/shop");
        }
    
    
        using (Html.BeginUmbracoForm<UmbLoginController>("HandleLogin"))
        {
            <fieldset>
                <legend>Login</legend>
    
                @Html.ValidationSummary("loginModel", true)
    
                @Html.LabelFor(m => loginModel.Username)
                @Html.TextBoxFor(m => loginModel.Username)
                @Html.ValidationMessageFor(m => loginModel.Username)
                <br />
    
                @Html.LabelFor(m => loginModel.Password)
                @Html.PasswordFor(m => loginModel.Password)
                @Html.ValidationMessageFor(m => loginModel.Password)
                <br />
    
                <button>Login</button>
            </fieldset>  
        }
    }

     

    Note - you need to change the line:

    HttpContext.Current.Response.Redirect("/shop");

    to be the URL of your shop. 

    3) Migrate from SQL CE - I've done this before using WebMatrix - use google or there is this: http://our.umbraco.org/projects/backoffice-extensions/export-sql-server-compact ;

    4) Template changes - this is a simple CSS task, please review the Youtube link earlier in the forum (how to use Dev tools to experiment with CSS) and use google to find out how to change background colours. 

  • Maxim 50 posts 69 karma points
    Jun 03, 2014 @ 18:36
    Maxim
    0

    Hi steve, 

    Sorry about all the questions at once. Yet the question about the color was unnecessary. After an hour of doing something else i remembered the vid on youtube. hehe ;p .
    All the other things i gonna check now.

    Here is my code of the login status: 

    @inherits Umbraco.Web.Macros.PartialViewMacroPage
    
    @using System.Web.Mvc.Html
    @using ClientDependency.Core.Mvc
    @using Umbraco.Web
    @using Umbraco.Web.Models
    @using Umbraco.Web.Controllers
    
    @{
        var loginStatusModel = Members.GetCurrentLoginStatus();
    
        Html.EnableClientValidation();
        Html.EnableUnobtrusiveJavaScript();
        Html.RequiresJs("/umbraco_client/ui/jquery.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.min.js");
        Html.RequiresJs("/umbraco_client/Application/JQuery/jquery.validate.unobtrusive.min.js");
    
        var logoutModel = new PostRedirectModel();
    
        @*
            Here you can specify a redirect URL for after logging out, by default umbraco will simply
            redirect to the current page. Example to redirect to the home page:
    
            logoutModel.RedirectUrl = "/"; 
        *@
    }
    
    @* NOTE: This RenderJsHere code should be put on your main template page where the rest of your script tags are placed *@
    @Html.RenderJsHere()
    
    @if (loginStatusModel.IsLoggedIn)
    {
        <p>You are currently logged in as: @loginStatusModel.Name</p>
    
        using (Html.BeginUmbracoForm<UmbLoginStatusController>("HandleLogout"))
        {
             <fieldset>
                 <legend>Logout</legend>
                 <button>Logout</button>
             </fieldset>
    
            @Html.HiddenFor(m => logoutModel.RedirectUrl)
        }
    }
  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 03, 2014 @ 19:01
    Steve Morgan
    0

    A few posts ago I suggested you added on the bottom:

    else
    {
       
    <p><a href="/login">Login here</a></p>
    }

    This line @if(loginStatusModel.IsLoggedIn) if false (as in you're not logged in) means that nothing will be output without this else.

  • Maxim 50 posts 69 karma points
    Jun 04, 2014 @ 16:40
    Maxim
    0

    Tried the migration of SQL, didn't work and now i can't login on umbraco anymore :/ I need to finish the big lines of the website by this evening. Maxim

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 04, 2014 @ 17:57
    Steve Morgan
    0

    What method did you try - what errors are you getting? I'd recommend starting a new forum post with specific questions to get fast answers but screen shot and give detailed steps as best you can. 

    Have you got a SQL Server DB from the migration? Can you login and have you changed the connection string in your web.config to use it?

  • Maxim 50 posts 69 karma points
    Jun 04, 2014 @ 19:18
    Maxim
    0

    Ill start a new thread for that. Do you know how i can change the label names from the register because now its in english and i want it in dutch. With inspect element on chrome i can change it but i don't find it in the macro itself tho

  • Maxim 50 posts 69 karma points
    Jun 04, 2014 @ 20:11
    Maxim
    0

    I finally got the login status in my footer. If you aren't logged in, it says click here to log in. When you log in you get redirected to the login page. But when you click the login button then it 'redirects' you to the same page but without lay-out. see screenshot below.
     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 05, 2014 @ 11:23
    Steve Morgan
    0

    1) Label names:

    Change the Partial View Macro Register - replacing the lines around line 62 with:

           @Html.LabelFor(m => registerModel.Name, "Voer uw gebruikersnaam")
                @Html.TextBoxFor(m => registerModel.Name, new { placeholder = "Gebruikersnaam" })
                @Html.ValidationMessageFor(m => registerModel.Username)
    
                <br />
    
                @Html.LabelFor(m => registerModel.Email, "Voer uw e-mail")
                @Html.TextBoxFor(m => registerModel.Email, new { placeholder = "E-mail" })
                @Html.ValidationMessageFor(m => registerModel.Email)
                <br />
    
                @Html.LabelFor(m => registerModel.Password, "Voer een wachtwoord")
                @Html.PasswordFor(m => registerModel.Password, new { placeholder = "Wachtwoordl" })
                @Html.ValidationMessageFor(m => registerModel.Password)

     

    2) See my earlier post (6th one down on page 3 http://our.umbraco.org/forum/umbraco-7/using-umbraco-7/53194-Need-some-help-?p=2) Don't forget to change your login page node id. 

     

    PS love the Dutch word for password - or at least what Google Translage thinks it is!

  • Maxim 50 posts 69 karma points
    Jun 09, 2014 @ 21:47
    Maxim
    0

    hi steve
    These are my last problems. Could you help me?

    I still have some small problems. I know why they are caused but yet i don't know how to solve them.

     

    • Ucommerce installed but no new tool in left colum. This is caused because i have SQL CE. I have to migrate it to sql server. But when i open my site in webmatrix i don't see a database.
    • Cultiv Razor contact form. I can't find where to change the mailfrom. So now you can fill in the contact form but it sends it to something random i guess. I need to change the mailfrom to my email. The cultirazor contact from is written in the old legacy razor, called DynamicNode razor, so i need to make some rewrite to get working with the Umbraco 7.1.3. I use what is called Partial View Macros or views. Somebody who knows how to solve this?
    • Last thing is that when you log in you get redirected to the page with ucommerce. 

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 10, 2014 @ 11:27
    Steve Morgan
    0

    Hi,

    I've no experience with Cultiv or your uCommerce redirect problem - I suggest you post a seperate thread for each of these issues as nobody is likely to wade through 5 pages here :)  

    For Webmatrix:

    Firstly, as always take a backup before you do this :)  

    For Webmatrix you need to click the DATABASES tab at the bottom left, select Umbraco.sdf and then the Migrate from the ribbon menu. 

    Fill in your details for your SQL server on the next screen. Then you need to check your web.config - I think WebMatrix tries to update this for you but check lines 50ish for your ConnectionStrings as it messed mine up when I tested it.  Check it references your SQL Server instance and remove (taking a copy!) any lines referring to CE.

      <connectionStrings>
        <remove name="umbracoDbDSN" />
        <add name="umbracoDbDSN" connectionString="server=STEVE-LAPTOP\SQLEXPRESS;database=UmbracoTest;user id=sa;password=HEREISYOURPASSWORD" providerName="System.Data.SqlClient" />
        <!-- Important: If you're upgrading Umbraco, do not clear the connection string / provider name during your web.config merge. -->
      </connectionStrings> 

    Finally as a paranoid check - create a content node in Umbraco and check that the id exists in your cmsContent table so that we're sure it's using your SQL DB! 

     

     

  • Maxim 50 posts 69 karma points
    Jun 10, 2014 @ 17:02
    Maxim
    0

    I know how to do it but i can't see any databases tho :/

     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 10, 2014 @ 18:10
    Steve Morgan
    0
    Copy and paste the Connections String settings section of your web config .. 

    <connectionStrings> <remove name="umbracoDbDSN" /> <add name="umbracoDbDSN" connectionString="server=XXXXX\SQLEXPRESS;database=XXXXX;user id=sa;password=XXXXX" providerName="System.Data.SqlClient" /> <!-- Important: If you're upgrading Umbraco, do not clear the connection string / provider name during your web.config merge. --> </connectionStrings> 
  • Maxim 50 posts 69 karma points
    Jun 10, 2014 @ 18:30
    Maxim
    0

    Found it.
    I was opening a wrong website. But they ask for a id and password. I know that the id is sa but what is the password or where can i find that? also as server there was ./sqlexpress, i changed it to maxim/sqlserver .

  • Maxim 50 posts 69 karma points
    Jun 10, 2014 @ 19:20
    Maxim
    0

    It stills gives me an error tho :/ it says it can't connect to it.
    Could you please help me? I don't want to be ruse or something but tomorrow i need to give my presentation about it tho :/ 

  • Maxim 50 posts 69 karma points
    Jun 10, 2014 @ 20:21
    Maxim
    0

    I can't log out on the site. I searched and I found the problem when you log that it didn't show. Now he shows you that you are logged in and redirects to the shop. but i can't log out. It redirects you to the login page without any lay-out. here is a screenshot when i just clicked logout:
     

  • Steve Morgan 1349 posts 4458 karma points c-trib
    Jun 11, 2014 @ 09:16
    Steve Morgan
    0

    1.  SQL Server

    a) I'm assuming you have:

    • An installed a local copy of SQL server (possibly Express) locally or you've been given the details of a network server?
    • You can connect via the SQL Server Management Studio software? 
    • You have checked the name of the instance of your server (as you seem to have guessed it's your computer name /SQLSERVER which is probably is but check!). - if it's on a server then replace "maxim" with the IP address or server name of your network server

      b) If it's a network server then you won't know the sa password so you'll either have to ask your network adminstrator for a sql user or first try using Integrated Security - change the drop down to "Windows Authentication" in Webmatrix and see if it connects. If you can just connect easily via the SQL Management Studio you're probably using that (it uses your windows account to log you in automatically). Either way you're going to need to update your Umbraco connection string accordingly. 

    I think it's this but you'll need to ask a new question in the forum otherwise as it may have changed since I last used Integrated Security (obviously update your server name and database name!):

    <add key="umbracoDbDSN" value="server=server\SQLEXPRESS;Initial Catalog=databasename;Integrated Security=True" />

     

    2.  Logout issues - it sounds like you don't have the redirect pages set properly. Right click on the node of the protected area and check that you have a page set for your Error node as well as your login. The error node should NOT be a protected page (your homepage is probably a safe option). 

     

Please Sign in or register to post replies

Write your reply to:

Draft