Active InfoActive Info  Display List of Info MembersMemberlist  Search The InfoSearch  HelpHelp
  RegisterRegister  LoginLogin
ASPProtect Version 8.x Support
 CJWSoft Support Info : ASPProtect Version 8.x Support
Subject Info: Access code buffer errors A d d  -  P o s tAdd P o s t
Author
Message << Prev Info | Next Info >>
cfromandi
New User
New User


Joined: February/15/2010
Online Status: Offline
Info: 2
Added: February/16/2010 at 5:08pm | IP Logged Quote cfromandi

I have successfully streamed a large zip file using your example file download code. It works great in itself. My issue is when adding the generated code for Group Access or Level Access I receive the following error:

<!-- Begin ASPProtect Code -->

<!-- Groups with access to this page. ( * My Group * ) -->

 

<!-- End ASPProtect Code -->

 

 <font face="Arial" size=2>

<p>Response object</font> <font face="Arial" size=2>error 'ASP 0157 : 80004005'</font>

<p>

<font face="Arial" size=2>Buffering On</font>

<p>

<font face="Arial" size=2>/aspprotect/users/stream_download.asp</font> <font face="Arial" size=2>, line 50</font>

<p>

<font face="Arial" size=2>Buffering cannot be turned off once it is already turned on.

</font>

I inserted the group access code I generated as below:

<%@Language="VBScript"%>

 

<!-- Begin ASPProtect Code -->

<!-- Groups with access to this page. ( * My Group * ) -->

<% GROUPACCESS = "2"%>

<!--#INCLUDE FILE="../check_user_inc.asp"-->

<!-- End ASPProtect Code -->

 

<%

Dim FilePath,downloaddirectory,filename

Const CHUNK = 2048

(rest of code)

 

Again If I remove the group access code (leaving only the <!--#INCLUDE FILE="../check_user_inc.asp"-->) line the file downloads like it should. While this solution prompts for a login, to the crafty person entering the download URL directly in the browser address it enables any user with a log on to download the file. Is there some tweak in the Group Access code that can resolve the issue.

 

Thanks,

Chris

Back to Top View cfromandi's Profile Search for other info by cfromandi
 
cwilliams
Admin Group
Admin Group
Avatar
CJWSoft Web Software Developer

Joined: April/06/2004
Online Status: Offline
Info: 1769
Added: February/16/2010 at 6:00pm | IP Logged Quote cwilliams

not exactly sure, but from what I recall when you're dealing with buffering and streaming you want no comments, line breaks, or spaces before the part of the code that streams out the file..

so try eliminating all the html comments and spaces and combining as many <%%> areas together as possible.. and literally have no line breaks.. You don't even want a line break before or after the include file gets called...

experimenting with that might very well solve your problem.. and leave out the language vbscript line as you don't need it.. it's the default..

So kinda like this.. right from the top of the source code.. with no line breaks spaces or anything..

<% GROUPACCESS = "2"%><!--#INCLUDE FILE="../check_user_inc.asp"--><%

Dim FilePath,downloaddirectory,filename

Const CHUNK = 2048

(rest of code)



__________________

Best Regards, Christopher Williams www.CJWSoft.com
Back to Top View cwilliams's Profile Search for other info by cwilliams Visit cwilliams's Homepage
 
cfromandi
New User
New User


Joined: February/15/2010
Online Status: Offline
Info: 2
Added: February/16/2010 at 6:19pm | IP Logged Quote cfromandi

Your recollection is outstanding. Your example did reslove the issue.

Thanks,

Chris

Back to Top View cfromandi's Profile Search for other info by cfromandi
 
cwilliams
Admin Group
Admin Group
Avatar
CJWSoft Web Software Developer

Joined: April/06/2004
Online Status: Offline
Info: 1769
Added: February/17/2010 at 2:48pm | IP Logged Quote cwilliams

excellent..

__________________

Best Regards, Christopher Williams www.CJWSoft.com
Back to Top View cwilliams's Profile Search for other info by cwilliams Visit cwilliams's Homepage
 

If you wish to make a comment to this info you must first login
If you are not already registered you must first register

  A d d  -  P o s tAdd P o s t
Printable version Printable version

Info Jump
You cannot add new info in this area
You cannot add to info in this area
You cannot delete your info in this area
You cannot edit your info in this area
You cannot create polls in this area
You cannot vote in polls in this area


Active Server Pages help tutorial how to ASP Help ASP Tutorials ASP Programming ASP Code - ASP Free CJWSoft ASPProtect ASPBanner ASPClassifieds www.aspprotect.com, www.powerasp.com,www.aspclassifieds.com,www.aspphotogallery.com,www.codewanker.com