ODBiC Discussion Board


RE: The files are accessible through a URL?, Roger Harris, 02-23-2006

Yes !

by Phil, February 23, 2006 14:11

Thx... I tried httpget yesterday and it didn't work; it works today... may be I was too tired. Here is my piece of code -with some french in it for practice ;-) WHILE loop is to extract the file name from a full qualified url.

<% SET trec = 75; DATABASE DSN=abcbase; SQL SELECT * FROM table WHERE prec = $trec$; SET pdown = $pnbrdowload$ + 1; NOTE SQL UPDATE; [to update counter] SET posfile = len($pnomfichier$), plienfichier = $pnomfichier$; WHILE $posfile$ > 0; SET posfile = pos($pnomfichier$,"/"); SET pnomfichier = $mid($pnomfichier$,$posfile$ + 1, len($pnomfichier$) - $posfile$); ENDWHILE; HEADER "Content-type: application/octet-stream"; HEADER "Content-Disposition: attachment; filename=$pnomfichier$"; HEADER "Connection: close"; HEADER ""; SETOPTION output_mode=B; HTTPGET http://$plienfichier$; EXIT; %>

Thx Roger for these nearly 10 years of support... I used ODBiC I guess around 1996-1997 for the first time on a Netscape server under Windows NT..


Replies:


Post Your Reply:

Name   
E-mail  optional
Topic  
Message:

HTTP Link: 
Link text: 

          


Copyright ©1997-2003, Roger Harris. All rights reserved.