0

Hi,

I have this website which I am developing, but it is having display problems.

I have a directory called 'includes' which contains 'header.php', 'login.inc.php' and 'login_form.inc.php'

'header.php' - displays the normal doctype, meta tags, styles, etc.
'login.inc.php' - is the actual process of the login form once the form is submitted.
'login_form.inc.php' - is the actual display of the form.

Then in the main root folder I have a file called 'index.php'. The code for this can be seen below:

index.php

<?php

        require ('./includes/config.inc.php');

        require (MYSQL);

       // This processes the login form for a user to log in.

        if ($_SERVER['REQUEST_METHOD'] == 'POST') {
               include ('./includes/login.inc.php');
       }

       include ('./includes/header.php');

?>

So that works fine to a certain extent, but then in the 'header.php' file I have the following:

<?php
if (isset($_SESSION['user_id'])) {
                        echo '<a class="dropdown-toggle" href="#" data-toggle="dropdown">Your Profile <strong class="caret"></strong></a>
                        <div class="dropdown-menu" style="padding: 15px; padding-bottom: 0px;">
<ul class="unstyled">
<li><a href="#">Change Password</a></li>
<li class="divider"></li>
<li><a href="#">Logout</a></li>
</ul>
';
} else {
        echo '<a class="dropdown-toggle" href="#" data-toggle="dropdown">sign in <strong class="caret"></strong></a>
                        <div class="dropdown-menu" style="padding: 15px; padding-bottom: 0px;">';
         include ('includes/login_form.inc.php');
} ?>

It works, it displays the form but then when you visit the website and try any other links like 'register.php' or 'search.php' or 'forgot password.php' all the user is greated with is just the header.php file and then a blank white page.

Any comments, suggestions, help would be much apppreciated.

Regards

PHP5,
MySQL
Chrome

4
Contributors
18
Replies
20
Views
4 Years
Discussion Span
Last Post by SunnySideUp
0

Unsure what should be shown on these pages. Could you elaborate?

One issue with 'nested' include files is that the file references can break, but that should give you an error. References should be made to fit the 'parent' page, else I think you can you can use __DIR__ to make the includes relative to the containing file.

Edited by diafol

0

Hi,

You can see the website at webzoost.com, but here are the files and what they do:

header.php (Displays the normal HTML for a webpage and also contains the website navigation for logged in users and visitors depending on if their is a session).

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">

    <link href="css/bootstrap.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">
    <link href="css/bootstrap-responsive.css" rel="stylesheet">

    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js"></script>

    <!--[if lt IE 9]>
      <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->

    <link rel="shortcut icon" href="img/favicon.ico" type="image/x-icon">
    <link rel="icon" href="img/favicon.ico" type="image/x-icon">
  </head>
  <body>
   <section class="navbar navbar-fixed-top">
    <div class="navbar-inner">
        <div class="container">
            <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </a>
            <a class="brand text-info" href="http://www.webzoost.com" name="top">abaloo</a>
            <div class="nav-collapse collapse">
<?php
if (isset($_SESSION['user_id'])) {
echo '<ul class="nav pull-right">
<li><a href="http://www.webzoost.com/postJob.php">post job</a></li>
<li class="divider-vertical"></li>
<li><a href="http://www.webzoost.com/resumeSearch.php">search</a></li>
<li class="divider-vertical"></li>
<li class="dropdown">
<a class="dropdown-toggle" href="#" data-toggle="dropdown">Your Profile <strong class="caret"></strong></a>
<div class="dropdown-menu" style="padding: 15px; padding-bottom: 0px;">
<ul class="unstyled">
<li><a href="http://www.webzoost.com/change_password.php">Change Password</a></li>
<li class="divider"></li>
<li><a href="http://www.webzoost.com/logout.php">Logout</a></li>
</ul>
</div>
</li>
</ul>
</div>
</div>
</div>
</section>';
} else {
echo '<ul class="nav pull-right">
<li><a href="http://www.webzoost.com/register.php">register</a></li>
<li class="divider-vertical"></li>
<li><a href="http://www.webzoost.com/search.php">search</a></li>
<li class="divider-vertical"></li>
<li class="dropdown">
<a class="dropdown-toggle" href="#" data-toggle="dropdown">sign in <strong class="caret"></strong></a>
<div class="dropdown-menu" style="padding: 15px; padding-bottom: 0px;">';
require ('includes/login_form.inc.php');
echo '</div>
</li>
</ul>
</div>
</div>
</div>
</section>';
}
?>

Then you have the 'login_form.inc.php'(this is the actual login form which resides in the same directory as the 'header.php' file and also the process file 'login.inc.php'.

<?php
if (!isset($login_errors)) $login_errors = array();
require_once ('./includes/form_functions.inc.php');
?>
    <form id="form-search" action="index.php" method="post"  accept-charset="utf-8">

        <?php if (array_key_exists('login', $login_errors)) {
            echo '<span class="alert alert-error">' . $login_errors['login'] . '</span><br />';
        } ?>

        Email
        <?php create_form_input('email', 'text', 'input-large', $login_errors); ?>
        <br />
        Password
        <?php create_form_input('password', 'password', 'input-large', $login_errors); ?> 

            <input class="btn btn-primary btn-block" type="submit" id="sign-in" value="Sign In">
    </form>
    <hr>
    <a href="http://www.webzoost.com/forgot_password.php" class="small">Forgotten Password</a>
    <br /><br />

Here is the 'login.inc.php' which is the process of the login form which is submitted straight to the 'index.php' form.

<?php
$login_errors = array();

if (filter_var($_POST['email'], FILTER_VALIDATE_EMAIL)) {
    $e = mysqli_real_escape_string ($dbc, $_POST['email']);
} else {
    $login_errors['email'] = 'Enter a valid email address<br />';
}

if (preg_match ('/^(\w*(?=\w*\d)(?=\w*[a-z])(?=\w*[A-Z])\w*){1,32}$/',$_POST['password']) ) {
    $p = mysqli_real_escape_string($dbc,$_POST['password']);
} else {
    $login_errors['password'] = 'You entered the wrong password<br />';
}

if (empty($login_errors)) { // OK to proceed!

    $q = "SELECT id, profile_type, date_joined  FROM Profiles WHERE (email='$e' AND password='"  .  get_password_hash($p) .  "')";      
    $r = mysqli_query ($dbc, $q);

    if (mysqli_num_rows($r) == 1) { // A match was made.

        $row = mysqli_fetch_array ($r, MYSQLI_NUM); 

        $_SESSION['user_id'] = $row[0];
        $_SESSION['username'] = $row[1];

        // Store the data in a session:
        // Only indicate if the user's account is not expired:
        //if ($row[3] == 1) $_SESSION['user_not_expired'] = true;

    } else { // No match was made.
        $login_errors['login'] = '<span class="alert alert-error">Email address and password do not match those on file.</span>';
    }
} // End of $login_errors IF.
?>

Then you have the final page 'index.php' which resides outside the includes folder.

<?php
require ('./includes/hidden');
require (MYSQL);
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
include ('./includes/login.inc.php');
}
include ('./includes/header.php');
?>

Obviously I have taken out the html, and also the footer.php link at the bottom of the page.

Any comments, suggestions would be much appreciated.

Regards.

Edited by SunnySideUp

0

So is this your structure:

root/
index.php
register.php
search.php
forgot_password.php
root/includes/
header.php
login.inc.php
login_form.inc.php
config.php
hidden (no file extension)

So which files are not getting included in index.php?

Edited by diafol

0

That is my structure, but:

A) did you actually visit the website ?
B) can you tell me why it is then that I cannot see the register page or the change password page once they are clicked from the homepage ?

In answer to your question:
the register page is not being loaded, the password change page is also not being loaded and all that is displayed is the header file ?

Any comments, suggestions would be much appreciated.

Regards.

0

A) yes
B) register loads, but nothing viewed under the menubar - login dropdown doesn't work

http://www.webzoost.com/search.php doesn't exist
http://www.webzoost.com/change_password.php like register.php

But that makes sense - you shouldn't be able to view change_password if you're not logged in.

Anyway, you're register page isn't displaying the login form because you've forgotten to include the js files at the bottom of the page. You can check this yourself with 'view source' in the browser.

0

Hi,

I can't even see the source of register.php, but it does include a file called footer.php which includes the JS files.
Why is it that the register page just displays the header.php file when that file is not even being called ? (Register page should display a sign up page)

I meant forgot_password.php was the other page that was white space ?

0

I'm not an expert by any measure, but it does seem to me that you've made your code overly complicated, simpler code makes simpler debugging, IMHO.

0

Hi,

Not really because this is an example from a book, the only difference in my example is that the navigation links are contained in the header.php file whereas the navigation links in the book are contained in the footer.php file.

Also when I have moved the navigation down into the footer.php the code worked fine, also when you click the register.php link it is continuosly getting the header.php file for some reason rather than the actual register.php file. On this occasion I do not wish for the navigation to be in the footer.php file.

Also have another question, in the phpinfo file under environment variables would the request method make a difference ?

Regards

0

I can't even see the source of register.php

Have a look in the browser's 'view source'. You're not including the last part of the page (footer??)

1

May I ask the OP, when you envision developing this site, did you write a barebone flowchart as to which file will include which one?

The reason I am asking is that, in a project of this size, there should be a file manager. For a much bigger one, there is file called director to direct all include and require requests of the scripts. Without these methods, it will be pretty hard to track down which files is needing another files.

A file manager is like a location map of your site. Similar to the one we see at the shopping complex. So, if page1.php needed to include page2.php, then page one must include the filemanager.php first, and include the page2.php. filemanger.php will take care of finding the page2.php. This is a common practice used in MVC framework and OOP.

Here is a simple filemanger-definition file based on Diafol's observed structure.

 ## not necessarily the first one, but let's define the directory separator
 define('DS', DIRECTORY_SEPARATOR);

 ## define the root directory where your script is going to run
 define('ROOT', dirname(__FILE__));
     ## define root directory files that will be included by another files
     // for example if the register.php is going to be included by another file, then it can be define as this
     define( 'REGISTER_FILE', ROOT.DS .'register.php' );

 ## define location of your includes directory
 define('INC_DIR', ROOT.DS .'includes');
     ## define files in include directory
     define('HEADER_PAGE', INC_DIR.DS .'header.php' );
     define('LOGIN_INC', INC_DIR.DS .'login.inc.php' );
     // add the rest of your files 

Now on the pages where a file or files needed to be included, we can easily include the file manager.

     include_once('filemanager.php');

     ## say, we want to include header.php, we can do so by just using the defined constant in the file manager.

     require_once( HEADER_PAGE );

That's pretty much it, for a more complex file manager example, it is normally written like this (see bonus codes below). This is the same class I am implementing on most of my projects..constants in the array are the files..This is my old version written way back in 2007. Not the best class I wrote, but it worked pretty well.

<?php
/*
 * Directory.class.php
 * Author: Veedeoo or PoorBoy
 * Copyright 2007 veedeoo.com tutpages.com 
 * 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 * MA 02110-1301, USA.
 * 
 * 
 */
## file function: This class include necessary files as needed. This file can work with the controller.

include_once( 'filedefinition.file.php' );

class Director{

public function __construct(){

}

public function getIncludeFiles(){

$includeTheseFiles = array( SMARTY_CLASS , CONTROLLER_FILE , DB_SETTING , DB_CLASS , PDO_CLASS );

self::setIncludeFiles($includeTheseFiles);

## instantiate the controller
return Instantiator::instance('Controller')->getContent();

}

private function setIncludeFiles($filesArray = array()){
          $incFiles = get_included_files();
          if((count($filesArray)>0)&&(count($incFiles)>0)){
          $arrayCount = array_intersect($filesArray,$incFiles);
             if(count($arrayCount)>0){
                return false;
             }
             elseif(count($arrayCount)<1) {
                  foreach($filesArray as $file_toInclude){
                     if(is_file($file_toInclude))
                        include_once($file_toInclude);
                    else{
                       return false;
                        }
                    }
                }   
            }
    else{
        return false;
        }
   } 
    }

I hope this will help you in the future. It may not make any sense today, but someday you will encounter too many files to include and can lost track of them. More importantly, if you will be venturing in OOP, then this is one out of too many ways of how the files can be manage.

Edited by veedeoo: info added

0

@diafol

In what file am I not including the 'footer.php' file ?

Also why is it only calling the 'header.php' file no matter what link you click(i.e. 'register.php','forgot_password.php')

@veedeoo, thanks for your help but I am not interested in an MVC/OOP solution.

0

I am not telling you to be interested in an MVC and OOP solution, what I am trying to portray on my example is to get your coding practices organize. That's simple....it will help you in debugging later on..sorry though good luck..

Edited by veedeoo: info added

0

@diafol

In what file am I not including the 'footer.php' file ?

Also why is it only calling the 'header.php' file no matter what link you click(i.e. 'register.php','forgot_password.php')

0

In what file am I not including the 'footer.php' file ?

I don't know what you call the include file with the following in it:

<script src="../js/jquery-1.7.2.min.js"></script>
<script src="../js/bootstrap.js"></script>
<script src="../js/cufon-yui.js"></script>
<script src="../js/Asap_400.font.js"></script>
<script src="../js/Coolvetica_400.font.js"></script>
<script src="../js/Kozuka_M_500.font.js"></script>
<script src="../js/cufon-replace.js"></script>
<script src="../js/FF-cash.js"></script>
<script>
    Cufon.now();
</script>

It's not in the register.php view source. So, you won't be able to disable the hidden property of the login form to make it visible when you click on the 'sign in' menu item.

BTW: Veedeoo makes some good points, like the one I mentioned about using __DIR__ , or as he puts it dirname(__FILE__), which is essentially the same thing. You don't have to use an MVC pattern/structure, but using a 'filemanager' as he terms it is a robust way of keeping track of your include files.

Personally, I go down the 'semi-MVC' route of using a single frontpage (index.php), using a template and just substituting the 'main stage' with content pages. A little bit of Apache mod rewrite allows meaningful urls. I'm also using Twitter Bootstrap - it's really cool.

e.g.
index.php

require('config/2364720p2742nfccb/config.php');
require(INC_DIR . 'header.php');
include(INC_DIR . $filepage);
require(INC_DIR . 'footer.php');

That's it. :)

config.php get the pagename to be displayed from the url ($_GET['page']), which is placed into the $filepage variable. It also does a lot more, but enough for now.

header.php contains the nav menu, breadcrumbs, loginform etc.

footer.php contains the bottom of the page, including script files for jQuery, bootstrap etc.

Anyway, just another way of doing it. You may find it less onerous.

+1 to Veedeoo.

Edited by diafol

0

Hi,

The code snippet your printed above is my 'footer.php' file, it is in every file that needs it. For the files 'login_form.inc.php' and 'login.inc.php' the footer.php file is not needed since the form is being submitted back to the 'index.php' page

Any other comments/suggestions ?

Regards

Edited by SunnySideUp

0

All your main display pages need the footer.php file including the register.php file. Your register.php file ends like this:

<div class="dropdown-menu" style="padding: 15px&#59; padding-bottom: 0px&#59;"><form action="index.php" id="form-search" method="post"  accept-charset="utf-8">

        Email
        <input type="text" name="email" id="email" class="input-large" />        <br />
        Password
        <input type="password" name="password" id="password" class="input-large" /> 

            <input class="btn btn-primary btn-block" type="submit" id="sign-in" value="Sign In">
    </form>
    <hr>
    <a href="http://www.webzoost.com/forgot_password.php" class="small">Forgotten Password</a>
    <br /><br />
</div>
</li>
</ul>
</div>
</div>
</div>
</section>

So your footer file is obviously missing.

Your login_form.inc.php does rely on the footer.php file as the footer file contains all the js files required to display it from the menu dropdown.

I don't know what else to suggest to you with regard to other comments, other than 'good luck'.

Anybody else like to suggest anything?

0

The source code you just printed, all that is in my 'header.php' file, thats what I said to you earlier when I said "all the links are doing is re-printing the contents of the 'header.php' file rather than the individual page contents ?

Anybody else like to suggest anything?

Adding the footer.php file didn't do anything either.

Anybody else like to suggest anything?

0

The source code you just printed, all that is in my 'header.php' file, thats what I said to you earlier when I said "all the links are doing is re-printing the contents of the 'header.php' file rather than the individual page contents ?

Anybody else like to suggest anything?

Adding the footer.php file didn't do anything either. Here is a copy of the 'register.php' page:

<?php
require ('./includes/config.inc.php');
include ('./includes/header.php');
require (MYSQL);

    $reg_errors = array();

    if ($_SERVER['REQUEST_METHOD'] == 'POST') {

        if (filter_var($_POST['accounttype'], FILTER_SANITIZE_STRING)) {
            $t = mysqli_real_escape_string($dbc,$_POST['accounttype']);
        } else {
            $reg_errors['accounttype'] = 'Please select an account type';
        }

        if (preg_match ('/^[A-Z0-9]{2,30}$/i',$_POST['username'])) {
            $u = mysqli_real_escape_string($dbc, $_POST['username']);
        } else {
            $reg_errors['username'] = 'Please enter a username';
        }

        if (filter_var($_POST['email'], FILTER_VALIDATE_EMAIL)) {
            $e = mysqli_real_escape_string($dbc, $_POST['email']);
        } else {
            $reg_errors['email'] = 'Please Enter A Valid Email Address';
        }
        if (preg_match ('/^(\w*(?=\w*\d)(?=\w*[a-z])(?=\w*[A-Z])\w*){1,32}$/',$_POST['password']) ) {
            if ($_POST['password'] == $_POST['password1']) {
                $p = mysqli_real_escape_string($dbc,$_POST['password']);
            } else {
                $reg_errors['password1'] = 'Your password did not match the confirmed password';
            }
        } else {
            $reg_errors['password'] = 'Please enter a valid password';
        }

            if (empty($reg_errors) ) {

                        $q = "SELECT email, username FROM Profiles WHERE email='$e' OR username='$u'";
                $r = mysqli_query($dbc, $q);

                $rows = mysqli_num_rows($r);

                                if ($rows == 0) {
                                        $a = md5(uniqid(rand(), true));
                                        $i = $_SERVER['REMOTE_ADDR'];

                                        $q = "INSERT INTO Profiles(profile_type,username,email,password,activation,date_joined,profile_ip) VALUES ('$t','$u','$e','" . get_password_hash($p) . "','$a',NOW(),'$i')";
                        $r = mysqli_query($dbc, $q);
if (mysqli_affected_rows ($dbc) == 1) {
                    //Send An Activation Email
                                            $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
                                                        <html xmlns="http://www.w3.org/1999/xhtml" xml:long="en" lang="en">
                                                        <head>
                                                        <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
                                                        <title>Abaloo - Activate Your Account</title>
                                                            <style type="text/css">
                                                                body,td,th {font-family: arial,sans-serif;font-size: 12px;}
                                                                body {background-color: #F0f0f0;margin-left: 0px;margin-top: 0px;}
                                                                p {color:#444;padding:0 0 0 8px;line-height:1.5em;}
                                                                h3 {color:#1e90ff;font-size:30;}
                                                                txtcolor{color:#1e90ff;font-size:30;font-weight:400;}
                                                                a{text-decoration:none;}
                                                                a:hover{text-decoration:underline;}
                                                            </style>
                                                         </head>
                                                         <body><center><br />';
                                              $message .="<table width=\"600\" border=\"0\" bgcolor=\"#FFFFFF\" cellpadding=\"20\">
                                                          <tr>
                                                            <td align=\"left\" bgcolor=\"#FFFFFF\"></td>
                                                          </tr>
                                                          <tr>
                                                          <td align=\"center\" bgcolor=\"#FFFFFF\">
                                                            <h3 class=\"txtcolor\" style=\"font-color:#1e90ff\">. Abaloo .</h3><br />
                                                            <p>
                                                                Thankyou for joining Abaloo.com, we are a small company offering services to Job Seekers, Employers and Recruitment companies. To
                                                                get your account up and running please activate your account by clicking the link below:
                                                            </p>
                                                            <p>";
                                                $message .= "<a href=\"" . BASE_URL .'profiles/activate.php?x=' . urlencode($e) . "&y=$a\" />Click Here To Activate</a>";

                                                $message .= "</p><br />
                                                            <p>
                                                                If the above link does not work then just copy and paste the link below to Activate
                                                            </p>
                                                            <p>";
                                                $message .= BASE_URL .'profiles/activate.php?x=' . urlencode($e) . "&y=$a";
                                                $message .= "</p>
                                                            <br />
                                                            <p>
                                                                Once your account has been activated you will be able to complete your profile. 
                                                            <br />
                                                            <p>
                                                                Yours Sincerely<br /><br />Abaloo
                                                            </p>
                                                            </tr>
                                                            </table>
                                                            <br /></center></body>
                                                            </html>";

                                                            $headers = 'MIME-Version: 1.0' . "\r\n";
                                                            $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
                                                            $headers .='From: webzoost.com <admin@webzoost.com>' . "\r\n" .
                                                                       'Reply-To: Admin@webzoost.com' . "\r\n" .
                                                                       'X-Mailer: PHP/' . phpversion();

                                                            mail($_POST['email'],'Webzoost.com, Activate Your Account',$message,$headers);
                                                            echo '
<section class="container">
    <div class="row">
        <div class="span3 sidebar">
            <!-- <div class="sidebar-settings">
                    <img src="images/gravatar.jpg" />
            </div> -->
                <div class="sidebar-detail">
                    <h3 class="txtCenter">. Features .</h3>
                        <dl>
                          <dt>Job Seekers</dt>
                          <dd class="small">Looking for a job, you should select Job Seeker, looking to find Job Seekers or advertise jobs then you should choose Employer or Recruiter.</dd>
                        </dl>
                </div>
         </div>
            <div class="span9 content-setting">
                <div class="content-settings">
                    <h3 class="txtCenter">. Activate Account .</h3>
                        <hr />
                        <p>
                            Thank you for joining Abaloo, to complete the activation process you will receive an email within the next
                            couple of minutes(Please be sure to check your spam/junk folders), please follow the instructions contained within
                            this email.
                        </p>

                </div>
            </div>
        </div>
</section>';
                                        include ('./includes/footer.php');
                                        exit();
                            } else {
                                 trigger_error('You could not be registered');
                           }
                              } else {
                                    if ($rows == 2) {
                                             $reg_errors['email'] = 'This email address has already been taken';
                                             $reg_errors['username'] = 'This username has been registered.';
                                     } else {

                                           $row = mysqli_fetch_array($r, MYSQLI_NUM);

                                           if( ($row[0] == $_POST['email']) && ($row[1] == $_POST['username']) ) {
                                                       $reg_errors['email'] = 'This email address has already been registered';
                                                       $reg_errors['username'] = 'This username has already been registered';
                                           } elseif ($row[0] == $_POST['email']) {
                                                       $reg_errors['email'] = 'This email address has already been registered';
                                           } elseif ($row[1] == $_POST['username']) {
                                                       $reg_errors['username'] = 'This username has already been registered';
                                           }
                                     }
                               }
                  }
         }

require ('./includes/form_functions.inc.php');      
?>

<section class="container">
    <div class="row">
        <div class="span3 sidebar">
            <!-- <div class="sidebar-settings">
                    <img src="images/gravatar.jpg" />
            </div> -->
                <div class="sidebar-detail">
                    <h3 class="txtCenter">. Account Help .</h3>
                        <dl>
                          <dt>Account Type</dt>
                          <dd class="small">Looking for a job, you should select Job Seeker, looking to find Job Seekers or advertise jobs then you should choose Employer or Recruiter.</dd>
                        </dl>
                        <dl>
                          <dt>Password</dt>
                          <dd>Password should be made up of between 1 and 32 characters consisting of small, uppcase letters and numbers .</dd>
                        </dl>
                        <dl>
                          <dt>Activate Account</dt>
                          <dd>Follow the instructions contained within the email to activate your account.</dd>
                        </dl>
                        <dl>
                          <dt>Complete Profile</dt>
                          <dd>Log in and finish your profile whether your a Employer, Job Seeker or Recruiter.</dd>
                        </dl>
                </div>
         </div>
            <div class="span9 content-setting">
                <div class="content-settings">
                    <h3 class="txtCenter">. Create Account .</h3>
                        <hr />

                        <form class="form-horizontal" action="register.php" method="post"  accept-charset="utf-8">
                            <div class="control-group">
                                <label class="control-label">Account Type</label>
                                    <div class="controls">
                                        <select class="input-large" name="accounttype">
                                            <option value="Employer">Employer</option>
                                            <option value="Job Seeker">Job Seeker</option>
                                            <option value="Recruiter">Recruiter</option>
                                        </select>
                                    </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">Username</label>
                                    <div class="controls">
                                        <?php create_form_input('username', 'text', 'input-large', $reg_errors); ?>

                                    </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">Email</label>
                                    <div class="controls">
                                        <?php create_form_input('email', 'text', 'input-large', $reg_errors); ?>

                                    </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">Password</label>
                                    <div class="controls">
                                        <?php create_form_input('password', 'password', 'input-large', $reg_errors); ?>

                                    </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">Confirm Password</label>
                                    <div class="controls">
                                        <?php create_form_input('password1', 'password', 'input-large', $reg_errors); ?>

                                    </div>
                            </div>
                            <div class="control-group">
                                <div class="controls">
                                    <label class="checkbox">
                                        <input type="checkbox"> Accept and agree to our Terms and Conditions and Privacy Policy.
                                    </label>
                                </div>
                            </div>
                            <div class="form-actions">
                                <input class="btn" type="submit" name="submit_button" value="Create Account" />
                            </div>
                        </form>
                </div>
            </div>
        </div>
</section>
<?php
    include ('./includes/footer.php');
?>

Anybody else like to suggest anything?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.