My host set me up an FTP server as well as a web server on my own IP address. I need to find a script (or write one) that, when the user tries to download something off my webpage, it will check the FTP server to see how many users are logged in, and if its more than like 15, deny access to the file.
can anyone set me off on the right foot? thanks.
check ftp server for number of connections?
Moderator: General Moderators
-
TheBentinel.com
- Forum Contributor
- Posts: 282
- Joined: Wed Mar 10, 2004 1:52 pm
- Location: Columbus, Ohio
Re: check ftp server for number of connections?
That's almost surely a configuration item on the FTP server. My provider tells me when I log on that I am "user #2 of 50 possible users" or something like that, and it's all coming from the server.ferric wrote:My host set me up an FTP server as well as a web server on my own IP address. I need to find a script (or write one) that, when the user tries to download something off my webpage, it will check the FTP server to see how many users are logged in, and if its more than like 15, deny access to the file.
can anyone set me off on the right foot? thanks.
If you check with your host, they can probably tell you what the setting is, or set it for you.
-
TheBentinel.com
- Forum Contributor
- Posts: 282
- Joined: Wed Mar 10, 2004 1:52 pm
- Location: Columbus, Ohio
I see. Well, you're outside my area of expertise (watching TV) so I can't say what's possible or not on the FTP server. It seems reasonable that the server could limit access in this way, but I don't know.ferric wrote:Yeah, it is set to 50. The thing is though, that like the 'videos' section of my site gets POUNDED with requests, and anyone trying to download sounds is out of luck. So, i'm trying to limit how many users the video's people take up.
You could sure do it in a browser with PHP, though. Would you be interested in changing from FTP to a browser/HTTP solution?