This is a discussion on "Delete file in password protected page." within the Classic ASP section. This forum, and the thread "Delete file in password protected page. are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
Delete file in password protected page.
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
|||
|
|||
|
Delete file in password protected page.
I'm trying to make a couple of files. One that sees if another file exists. If it does, a link will appear to another file that will delete this file. I have everything working on my home pc, but when I try it on the websever, it says that I don't have permission.
I am assuming that is because the file is in a password protected folder. I was wondering if there was a way to supply this username and password in my asp file? Or if I change my code somehow it will delete the file?
|
|
|
|
#2
|
|||
|
|||
|
Re: Delete file in password protected page.
I don't know if this is correct, but in php I think you would have to change the chmod of the file to enable it to read, write and execute commands. If this is correct you would need to change it to 777 which you can do using your FTP agent.
I know absolutely nothing of ASP so please don't blame me if this is completely incorrect |
|
#3
|
|||
|
|||
|
Re: Delete file in password protected page.
Thanks djme, but this won't work. This is a Windows server so there is no chmod. I can delete the file using my ftp program, but I am trying to create a page that will do this to make it easier.
Basically, what I would like to do is have a cronjob for this, but as far as I know, there is no easy way to do this on a Windows server. |
|
#4
|
|||
|
|||
|
Re: Delete file in password protected page.
is the file in question in the same directory as the file you wish to delete?
|
|
#5
|
|||
|
|||
|
Re: Delete file in password protected page.
No it is not. I'll give that a try.
Edit: I moved the file to the same folder and I still get the error message. Quote:
fs.DeleteFile "C:\websites\mysite\protectedfolder\file.ext", true Last edited by SweetLou; Jan 7th, 2006 at 21:26. |
![]() |
| Tags |
| delete, file, password, protected, page |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [SOLVED] Connection string for password protected databases | alexgeek | Classic ASP | 6 | Oct 31st, 2007 15:59 |
| Password protected pages | wayne47 | Web Page Design | 9 | May 8th, 2007 14:16 |
| password protected photo gallery | milly | Starting Out | 1 | May 8th, 2007 00:33 |
| Best script to create users for password protected pages? | vandiermen | PHP Forum | 3 | Apr 23rd, 2007 12:22 |
| Delete All Record in a search result page? | Monie | Classic ASP | 3 | Nov 11th, 2004 03:27 |