Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Need Help with Simple Login Page with One Username and Password

Featured Replies

Hello Folks!

 

I need some direction. I am not very good with PHP but can do well with following tutorials. I am trying to make a simple login page that uses only one or two different passwords. Please help! :-) Any great sites that help with this? Any videos that you would suggest? Thanks in advance.

Hi Buddy

 

For that you just need to learn $_POST variables and If statements

 

1) Set up a form on your HTML page target="nameofphpfile.php" method="post"

 

2) Inside "nameofphpfile.php" have the following

 

$actual_user = 'tom';

$actual_password = 'tomspass';

 

$entered_username = $_POST['username'];

$entered_password = $_POST['password'];

 

3) Then we check that the POST variables match the user and pass we set so we would put

 

if($entered_username == $actual_user && $entered_password == $actual_password){

 

// User has now logged in

 

 

}

 

 

The concept is here, but its very very basic at the minute.

 

 

if your wanting to create a login section which keeps the user logged into the website whilst they're browsing etc, you need to learn sessions and mysql;

 

 

Anyway if you want any help drop me a PM, im happy to help :)

 

 

T

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.