Aymeric, that's almost exactly what I did for an app that sort of
disintegrated (funding dried up).  The last obstacle I faced before having
to call it quits was the fact that if you do the following:

default.asp:

if Len(request("action")) = 0 or session.userid = 0 or request(�action�) <>
�act_check_action� or request(�action�) <> �dsp_login� then
***************************************************
 Dim foo
 foo = "This is a test"
***************************************************
 server.execute "default.asp?action=dsp_login "
else
 if request(�action�) <> �act_check_action� then
  server.execute �default.asp?action=act_check_action&name=� &
request("action")
 end if
 server.execute request("action") & ".asp"
end if


Then in default.asp?action=dsp_login can not read the value of foo.  It can,
however, read anything in request() from default.asp.  How did you work
around this?   My plan was to write my code in such a way that any include
would have all of the information it needed to execute stored within a
session object (of which I rolled my own using a SQL Server db and caprock's
propertybag object), which should scale nicely and doesn't have the thread
affinity probs, etc. usually associated with the built-in session
management.

Very curious on this one!

Thanks!

____________________________________________

Chris Chambers

ICQ: 40311211
AIM: CTC HOME

Vox: 757.896.6393
Fax: 757.896.0774
____________________________________________

-----Original Message-----
From: Aymeric Grassart [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 17, 2000 11:10 PM
To: [EMAIL PROTECTED]
Subject: RE: ASP and Fusebox?


Attached at the bottom is a first attempt of documentation for Fusebox in
ASP.

After having tested it, we found out that all subs & functions within your
server.executed file are black-boxed; they are not accessible by other
included files. This makes things very hard.

If anyone finds a work-around, let me know...

--
Aymeric Grassart        <->     Chief Technology Officer
http://www.aylo.com     <->     Aylo Inc.


ASPBox

1)      Give the current most common and popular ASP methodology and explain why
this may not be a perfect one.
a.      Form posts redirect to the same file, which contains conditional
statements at the top of the page. These conditional statements do db calls
and other modifications to variables and then decides
b.      This method makes it very hard to go through your code, as navigation is
decided within each called pages.

2)      Summarize what a ASPBox methodology could provide.
a.      ASPBox is based on FuseBox (http://www.fusebox.org), a ColdFusion coding
methodology. This guide is intended for developers who already
understand the basics of Fusebox.
b.      A working global template mechanism that allows you to control the
navigation and functionality of a site through one main script page.
c.      Microsoft seems to support this technique. They attempted to centralize
control through a global.asa file (which has its problems.)

3)      Explain why this is not possible before asp 3, IIS 5 (vbscript engine
version ?)
a.      Didn�t allow server.execute function
i.      ASP did not allow dynamic include (whether surrounded by conditional if
statements or through dynamic urls)
ii.     In IIS 5, server.execute function can act as a ColdFusion cfinclude.
b.      Didn�t allow server.transfer function
i.      Although response.redirect was there, it added overhead of having to go
back to IIS and then redirect; this function is identical to the cflocation
tag in Cold Fusion. Would this mean a performance improvement in ASP
creating redirects than in ColdFusion ?)

4)      Knowing all passed variables can be accessed through one scope save quite
a bit of time. The ASP request object has 2 types of scopes, form(form) and
querystring(url.) If, while calling the object, these are omitted (as they
are above),
they will take their correct precedence order (forms overide urls.) This
acts as a basic work-around to Fusebox FormURL2Attributes.cfm module.

5)      Below is a sample skeleton file structure and sample code:

[default.asp � using the regular FuseBox-style technique]

if Len(request("action")) = 0 or session.userid = 0 then
 server.execute "dsp_login.asp"
else
select case request("action")
 case "showarticles"
  server.execute "dsp_header_articles.asp"
  server.execute "dsp_articles.asp"
  server.execute "dsp_footer_articles.asp"
end select
end if


[default.asp � using the ASPBox variation]

if Len(request("action")) = 0 or session.userid = 0 or request(�action�) <>
�act_check_action� or request(�action�) <> �dsp_login� then
 server.execute "default.asp?action=dsp_login "
else
 if request(�action�) <> �act_check_action� then
  server.execute �default.asp?action=act_check_action&name=� &
request("action")
 end if
 server.execute request("action") & ".asp"
end if


------------------------------------------------------------------------------
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/fusebox or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to