Hello Ben, One thing that I would recommend is breaking out the dashboard and login pages into their own separate URLs. You could even have the dashboard at the root URL but I would still recommend moving the login page to it's own endpoint. The basic idea would then be to redirect a non-logged-in user to the login URL if they attempt to visit the dashboard and redirect logged-in users that attempt to visit the login URL to the dashboard URL. This approach would be considered the best practice for dealing with authenticated and unauthenticated users.
A great resource worth looking into would be the Pyramid Auth Demo <http://michael.merickel.org/projects/pyramid_auth_demo/>. The demo goes over things like implementing the login endpoints (a.k.a. login *views* in Pyramid) and securing endpoints - which seems like what you are aiming for with the dashboard. Anyways, I hope that answers your question. -Vincent On Sat, Mar 12, 2016 at 10:30 AM, benjamin scott <[email protected]> wrote: > I'm still a bit new to pyramid and python. > > My question is how to render a users dashboard at the root url when > they're logged in? > > When not logged in the root url would have a sign in form. > > I've searched an have only found examples of this with other frameworks. > > Ben > > -- > You received this message because you are subscribed to the Google Groups > "pylons-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/pylons-discuss. > For more options, visit https://groups.google.com/d/optout. > -- Vincent Catalano Software Engineer and Web Developer, (520).603.8944 -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/pylons-discuss. For more options, visit https://groups.google.com/d/optout.
