Make a class that inherits from Umbraco.Web.UmbracoApplication
Implement Session_Start
Change your Global.asax file to point to the new class you made
Example:
using System;
namespace My.Namespace
{
public class Global : Umbraco.Web.UmbracoApplication
{
protected void Session_Start(object sender, EventArgs e)
{
//Do your thing
}
}
}
Ahh.. I think that may be the issue (I didn't write this code)..
I had this..
using System;
namespace My.Namespace
{
public class Global : Umbraco.Web.UmbracoApplication
{
protected void Session_Start(object sender, EventArgs e)
{
//Do your thing
}
}
}
How to use SQLServer SessionState database in Umbraco?
My custom sessionstate database (SQL Server) is not being populated when the sessionstate configuration is setup in the Umbraco site web.config.
I think it is because Session_Start is not firing!?
Can anyone tell me how to implement Session_Start in Umbraco in Global.asax !? SQLServer session database not working..
SessionState Connectionstring is fine as it works on a blank web application so it must be how Umbraco handles Session_Start (or doesn't!)
I'm using Umbraco 6.1.2.
Thanks
-- Lee
Have you tried http://stackoverflow.com/questions/15872770/global-asax-in-umbraco-6
I think this will help: http://stackoverflow.com/questions/15872770/global-asax-in-umbraco-6
Basically:
Example:
Global.asax should then look like this:
Yes but Session_Start still doesn't get called. Any ideas?
-- Lee
@Lee What exactly have you done? Example code please?
Ahh.. I think that may be the issue (I didn't write this code)..
I had this..
But my Global asax was
Instead of
Session_Start now firing!! yey!
Cheers guys!
-- Lee
is working on a reply...