Conditional server side code - triggered by client

Results 1 to 2 of 2

Thread: Conditional server side code - triggered by client

  1. #1
    Karl Guest

    Default Conditional server side code - triggered by client

    Hi,<BR><BR>I am transferring files from the server to the client, using a combination of server-side and client side code - the server side generates a list of files and their locations on the server and the client code transfers them to the local machine.<BR><BR>However, I have come across a problem, which I&#039m sure should be easy to solve. Once the file is transferred, I check for the existence of the file on the local machine (using client-side code). If the file exists, I then want to set a flag in the database to mark it as transferred.<BR><BR>I can&#039t seem to find the right way to do this since if I put the server side code in the page that will run before any of the client code (and hence flag everything as transferred even when it is not). Can anyone suggest a solution?<BR><BR>The pseudo-code would be a bit like:<BR><BR><BR>Generate list of files <BR>Do while not end of list <BR> transfer file <BR> check if file exists <BR> if exists then set flag <BR> move to next in list <BR>Loop <BR><BR>All code is written in VBScript (it only has to run on IE). <BR><BR>Thanks in advance<BR><BR>Karl Elisha<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Conditional server side code - triggered by cl

    I guess the only thing you can do is to do a Self-Post to the same ASP page. It could be either GET or POST of a form. Then on top of the Server saide script put a special check to determine if this is a result of a Self Post.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts