In the home page (index.php): - Create a simple HTML content to welcome the user and simple paragraph to explain your assignment Below the above-mentioned content (HTML elements), create a login form that is consisted of two input fields: - Email → of type email - Password → of type password The form will be submitted to the same page, so place all your PHP code for manipulating the form submission on the top of the file (Before starting your HTML code, not in between): - First: Verify that both input boxes are not empty - Second: Verify that email address matches the normal email pattern: using the built-in PHP email check function although type="email" - Third: Verify that both user's info (email and password) are exists (an existing member that has a record on the users table) using the PHP/SQL code to scan the users' table. You will to define the host name, database name, user name, and password plus execute and test the PDO object - Using the proper PDO method for the PDO object, set the default value for fetching your data to be in "Associative Array" format - Notice that this file "dbconfig.php" is required to be loaded in any page that interacts with the database (HINT: You can include it in the header.php) Create a folder named "config" that contains: - PHP file: dbconfig.php - This PHP file will contain the required information to connect your PHP code of your assignment to the database (the tables) using PDO. Although it's nice to style your webpages in professional way using the skills and techniques that you have learned in your course "Interface Design".Ĩ. Please be advised that you don't have to use the same ids, classes names, or the same structure! Feel free to use any name for your CSS classes and ids if there are any. The following code that represents the bottom part of the page must be inside the footer.php file: >Developed By: Group X: Alex Chow, Martin Smith, and Sam Simpson > 7. The following code that represents the top part of the pages, has to be inside the header.php file: PHP files: header.php: contains the top part of the HTML Code and other PHP required code footer.php: contains the bottom part of the HTML Codeĥ. Create a folder for the page templates named "templates" that contains two. Create a website of 4 pages: Home page (index.php): The first default page when the user visits the website Member page (member.php): For the logged in users (Members only) Registration page (register.php): For registering a new user Contact Us form page (contact.php): For contact us form (using email) 4. You have to add useful and detailed comments to explain your code lines for these reasons: ✓ to make it easy to read and understand ✓ to show that you know what you are doing and how to use PHP statements ✓ to be used as a proof that you're the programmers of this code 3. (The folder of the assignment must be created inside "htdocs" which is inside "xampp"): 2. You can either create a new PHP project (folder) using VS Code, NetBeans (IDE), or any IDE that you prefer with any name like "PHP-Assignment 3 " and save it inside the server folder "htdocs".
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |