Is there a way to extend the ASP class session every time an ASP.NET request is made?

I have a website that is running both classic ASP and ASP.NET Webforms. The sessions are separate for each.

I need to hit an asp page whenever a request is made in ASP.NET pages.

Why? As I need to expand my ASP session so it doesn't expire.

I know this will cause a number of problems, and I really don't want to, but the solution is not in my hands unfortunately.

Is there a way to accomplish what I am trying to do?

+2


source to share


4 answers


Put .asp page inside iframe

in asp.net page? Just to clarify here ... you don't need to make the iframe visible. 0px or whatever you want. But load it into the src = attribute.



+3


source


Do you have a link to the ASP script file to do anything in the ASPX page? Or look at something like this .



Refresh - as you say, you don't have master pages or something. You can use HttpModule to inject additional HTML required to request a classic ASP page. See here for an article on how to do this , or see the code for it . Making one for your needs won't be difficult. Find where you want to paste it and add additional HTML.

+1


source


This might be a half hack idea, but maybe on some pages redirects to an asp page, then that page just redirects back to the calling asp.net page, I mean it all depends on which pages are doing something but you can see where i'm heading with this

0


source


Add an img tag to a page that targets one of the ASP pages in your application. Add a CSS class to the image that hides it and puts something random or current date in the query string so it won't get cached just to be safe.

0


source







All Articles