Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Global.asa

Thread Tools


Posts: n/a

I'm using Global.asa on my web site, our Web server migrate to a new server from Platform WinNT to Platform (Nt+ Unix) do te server will not support Global.asa

My question is:

in the global.asa I have this code:

'Session_OnStart Runs the first time a user runs any page in your application
'Session_OnEnd Runs when a user's session times out or quits your application
<script LANGUAGE="VBScript" RUNAT="Server">
Option Explicit
Sub Session_OnStart

' Enable = 1 disable = 0
Session("DownloadEnable") = 1
Session.Value("szVerMaj") = "5"
Session.Value("szVerMin") = "8"
Session.Value("szComp") = "225"
Session.Value("szFile") = "27 Mo"

end sub
end script

On file which use the session in global.asa is: Download.html

<% if Session.Value("DownloadEnable") = "1" then %>
b><font face="trebuchet ms,verdana,arial,helv" color="#000033" size="-1">Before
downloading the Demo Copy</font></b><p><font face="trebuchet ms,verdana,arial,helv" color="#000033" size="-1">Complete
the form below in order to let us generate your
authorization number.</font>
end if

So I'm using the sessions in almost all my pages

Now I have to replace my Global.asa with GlobalVar.asp and I have to include it in all my pages. I rename Global.asa to GlobalVar.asp and I included it in one page to test but it's not working well

I put on my download.html after my Javascript code:

<!--#include file="GlobalVar.asp"-->

but when I test the page Global.html I do not a page to display

Any help please do I have to rename my session to a sample Variable:
Session("DownloadEnable") = 1
Dim DownloadEnable
DownloadEnable = 1


Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off