473,386 Members | 1,841 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

How to enable site downloads after user is given password?

I'm looking for a ready package or shareware that will let visitors to
my site download individual files after I mail them the password. I'm
not looking to encrypt the files and don't care if the visitor mails
them to others after download.

Thanks
Nat

Jul 23 '05 #1
6 1247
<na*******@yahoo.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
I'm looking for a ready package or shareware that will let visitors to
my site download individual files after I mail them the password. I'm
not looking to encrypt the files and don't care if the visitor mails
them to others after download.

IMO, you need to handle this in server side script. (it may be doable in JS
on serverside, but I've never seen it)

if( server == "Windows")
document.location.href = "microsoft.public.dotnet.framework.aspnet";
else
document.location.href = "comp.lang.php";
Good luck.

--
Regards,
John MacIntyre
http://www.johnmacintyre.ca
Specializing in; Database, Web-Applications, and Windows Software

Jul 23 '05 #2
ASM
na*******@yahoo.com a ecrit :

I'm looking for a ready package or shareware that will let visitors to
my site download individual files after I mail them the password. I'm
not looking to encrypt the files and don't care if the visitor mails
them to others after download.


do you mean the visitor fill a form (with his url) and on submit
the form mails to him the password ?

or
do you only need that filling a password
will send visitor to the download page ?

you can use a password wich is the name of download page

password_page.htm

<html><title>Pass to downloads</title>
<form onsubmit="var download = 'myfolder'+this[0].value+'.html';
ici=window.open(download,'','width=400,height=300, scrollbars=1,resizable=1');
return false;" style="text-align:center">
Enter your password here :<br />
<input type=password><br>
and press [Return]
</form></html>

myfolder = folder where are the download pages or relative path to them

if password is wrong (not the name of file without its suffixe '.html')
the server will send its error page 404

--
************************************************** *****
Stéphane MORIAUX et son vieux Mac
************************************************** *****
Jul 23 '05 #3
no real password protection possible with javascript, because it's
client side and therefore readable by the client.

you have to use some server side method (i.e. php) to protect your
files

micha

Jul 23 '05 #4
na*******@yahoo.com wrote:
I'm looking for a ready package or shareware that will let visitors to
my site download individual files after I mail them the password. I'm
not looking to encrypt the files and don't care if the visitor mails
them to others after download.


Access control is built in to just about every reasonable web server. For
Apache, look at the documentation for the .htaccess file. You can trivially
set it up so that a particular set of pages are protected by a username and
password; no Javascript or, indeed, anything other than HTML 1.0 are
required.

(Dynamically adding users is a more complex problem, but only a little so.)

--
+- David Given --McQ-+ "There is no expedient to which a man will not
| dg@cowlark.com | resort to avoid the real labour of thinking." ---
| (dg@tao-group.com) | Thomas Edison
+- www.cowlark.com --+

Jul 23 '05 #5
chotiwallah wrote:
no real password protection possible with
_client-side_
javascript, because it's client side and therefore readable by the client.


Yes, but it is well possible and secure with server-side J(ava)Script.
Consider JScript in ASP, for example.
PointedEars
Jul 23 '05 #6
David Given wrote:
Access control is built in to just about every reasonable web server. For
Apache, look at the documentation for the .htaccess file. You can
trivially set it up so that a particular set of pages are protected by a
username and password; no Javascript or, indeed, anything other than HTML
1.0 are required.


You mean _HTTP/1.0_. I doubt there was an implementation of
HTML 1.0 in an UA other than TBL's test implementation :)
PointedEars
Jul 23 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: John | last post by:
Hello. I want to get this blasted .htaccess file sorted out, so I can have sessions without register_globals being on. I have looked everywhere for info on this and I mean everywhere...
2
by: Rickard | last post by:
OK. I have the need on a form submit to pass the data to anther system that require a login and password only I want to automate the process in an server side asp file and then process the...
3
by: Nobody | last post by:
This problem has been challenging me for several days now. I have a web site that uses the usual, mundane Basic Authentication. But, now I have a request (actually, a demand) that users from a...
1
by: Angelo | last post by:
Hi, I've been trying to create a user in Active Directory. So far this works, however default the user is disabled. I've been trying so much code to enable the user, but without success, perhaps...
0
by: Gareth | last post by:
Can somebody help me with the following problem I have? Configuration: 1 x Microsoft Windows Server 2003 Web Edition + IIS 6.0 + ASP.NET 1 x Microsoft Windows Server 2003 Standard Edition +...
4
by: Steve Richter | last post by:
can File.Copy be use to copy files from my PC to the file system at my shared hosting web site? If so, what is the format of the path name of the file on the web site? The idea being that if I...
0
by: gabedog | last post by:
What would be a good (and safe) way to enable/disable a web site in a web farm that needs to come down for maintenance? Periodically, we have db folks that run db scripts. I'd like to put a back...
7
by: monomaniac21 | last post by:
hi i have a php site which allows users to save a cookie on their computer which stores their user id details and allows them to auto- login. i'm wondering whether this is safe, is it...
3
by: Pietro | last post by:
Hi all, First of all I'd like to thank you very very much ,as finally after many years of searching,I could find a code to disable/enable the shift key,but actually i cannot use the code as I'm...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.