Honesty Rocks! truth rules.

How To Add Login Page To Html File.

HOME      >>       Websites and Web Designing




I have a .html file that inside uses xhtml 1.0 strict, it uses a external style sheet.


Is it possible to create a login and register page using php and another html or php that also uses the css style sheet?

E.G. the login and register forms should be in the


<div id="main">

login/register form here





Is there a simple tutorial for this online that works?




How about creating an input box in a form and action on submit call a php and save your info to MySQL database?




This should have some examples that you can look at.


Here is an example of a basic login form in HTML, if that's what you're looking for:

<form action="login.php" method="POST"><fieldset><legend>Login</legend><p> Email address: <input type="text" name="email" /> </p><p> Password: <input type="password" name="password" /></p></fieldset></form>

Not sure what you are asking about the CSS style sheet, but if you need PHP code then feel free to ask further.


There are some good examples of how php handles login forms and how to create user accounts in the programming -> php section of this forum, but you can't process login data using html. You could I suppose use a .htaccess and .htpassword file however php is definately more flexible and secure.