Results 1 to 3 of 3

Thread: Need simple way to password protect a web page..

  1. #1
    Join Date
    Sep 2016
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Need simple way to password protect a web page..

    I am using turn.js to make a webpage flip book that looks like a magazine. Security is not a big concern, however, I'd still like to be able to keep the average person from viewing it.

    I first tried this:

    http://www.javascriptkit.com/epassword/index.htm

    Didn't work for me.

    I then tried Gatekeeper from here:

    http://www.javascriptkit.com/epassword/index.htm

    Followed the instructions. Does nothing. I tried with my webpage named .htm and .html. Neither worked. The password is the same name as the web page minus the extension. Enter password and it just sits there.

  2. #2
    Join Date
    Sep 2016
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    why dont you change the password? as I have never concerned with like this but I think if possible you can do it
    Change what password? The webpage has no password at the moment. There is no password to change.

    If you are referring to the two things of javascript code I linked above, I can't get them to work.. so changing the password has no effect.

  3. #3
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,377
    Thanks
    77
    Thanked 3,421 Times in 3,382 Posts
    Blog Entries
    12

    Default

    Well, in your host's configuration, there very likely is a simple method for adding password protection to a page. These generally work via what is known as .htaccess (a file that tells the server to require a username and password for a given page or folder), or sometimes PHP. Not every host makes this available, but those that do usually have a simple way that does all the work for you. Of those that don't, often one can make and upload a .htaccess file or make a PHP one to accomplish this. PHP is actually very easy if all you want to do is protect one page. But it requires that the host support PHP on your pages. If they do and you're interested, I will give you a simple method using PHP. With the PHP approach one can require either username and password, or just password if that's preferred - all of the above methods are very secure.

    Now, as to what you have tried, you mention two methods, but there is only one link, repeated twice, both go to the same "JavaScript Kit Encrypted Password Generator" page. Probably just a typo on your part that happened. And, as I suppose you know, javascript doesn't actually secure a page, just makes it a little inconvenient to see the page if you don't know the password.

    Dynamic Drive has such code as well - javascript also, so not really secure, you could try that:

    http://www.dynamicdrive.com/dynamicindex9/password.htm

    It's virtually impossible for us to tell what went wrong without seeing a live page that includes your attempt at making it work. If you've only tested locally, it's possible that something about the local environment prevented the javascript code from working properly. If you've tried it live, a typo/mistake in its implementation, or a conflict with other javascript code could be to blame. There could even be a combination of issues preventing it from working as expected for you. No way to know for sure without seeing what you tried that did not work. So, if you want more help with a javascript approach, please post a link to the page on your site that shows the problematic code.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Similar Threads

  1. Password protect a site
    By pckelly1369 in forum JavaScript
    Replies: 0
    Last Post: 01-19-2015, 04:37 PM
  2. Password protect 1 page
    By Chef in forum Looking for such a script or service
    Replies: 2
    Last Post: 09-11-2007, 01:59 PM
  3. Password Protect a Page Script Help
    By isamarlow in forum JavaScript
    Replies: 24
    Last Post: 03-01-2007, 06:00 PM
  4. password protect page
    By gell in forum Looking for such a script or service
    Replies: 2
    Last Post: 12-07-2006, 11:33 AM
  5. Replies: 0
    Last Post: 08-17-2005, 01:51 AM

Bookmarks

Posting Permissions

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