Sars! Posted November 5, 2006 Share Posted November 5, 2006 How can I integrate a popup in my website, which asks the people for an username and password, before they can continue? It looks like this:Username:Password:Remember PasswordGreetingsSars!ps: Whooow, that's a while ago since I came here! Link to comment Share on other sites More sharing options...
Chozo4 Posted November 5, 2006 Share Posted November 5, 2006 (edited) This should do the trick as it's also the most compatible with browser settings. Do note that it requires the use of PHP. http://www.zend.com/zend/tut/authentication.phpthe following entry of interest from the url would be this...<?php if ((!isset( $PHP_AUTH_USER )) || (!isset($PHP_AUTH_PW))) { header( 'WWW-Authenticate: Basic realm="Private"' ); header( 'HTTP/1.0 401 Unauthorized' ); echo 'Authorization Required.'; exit; } else { echo "You entered $PHP_AUTH_USER for a username.<BR>"; echo "You entered $PHP_AUTH_PW for a password.<BR>"; }How you check for valid user/pass info is up to you. You have several ways to try it in the url posted.... good luck Edited November 5, 2006 by Chozo4 Link to comment Share on other sites More sharing options...
Sars! Posted November 5, 2006 Author Share Posted November 5, 2006 Ok, I don't know any coding s***, I only do design... So, maybe a little bit more detailed? I don't understand anything! Link to comment Share on other sites More sharing options...
ripken204 Posted November 6, 2006 Share Posted November 6, 2006 how do u design without coding Link to comment Share on other sites More sharing options...
Sars! Posted November 8, 2006 Author Share Posted November 8, 2006 how do u design without coding I make websites with photoshop. Which I transfer to imageready, which I save as html + images which I add text with dreamweaver...Simple as that! Though my question needs an answer, a simple one! Link to comment Share on other sites More sharing options...
ripken204 Posted November 10, 2006 Share Posted November 10, 2006 well you will need to know coding, as we stated. just read that webpage the was given. you code will have to access some sort of a database or file to check if the username+password is valid. Link to comment Share on other sites More sharing options...
Sars! Posted November 19, 2006 Author Share Posted November 19, 2006 Thanx a lot!Though I still got some problems...My htpasswd file contains this:dubois:2rBUu9PUNkpa2Which should be:dubois:duboisBut if you test it here:Click Here To TestIt doesn't work!Anyone please help me!Grtz,Sars! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now