WEB-230-072 | Using htmlentities for Security | Assignment
Complete the following:
- Create a folder in your “htdocs/series/” folder named “using-htmlentities-for-security”.
- Create a file in your “htdocs/series/using-htmlentities-for-security” folder named “index.php”.
- Write the code that that results from using-htmlentities-for-security video.
- Answer question 1 commented in the code with commented answers in your code.
- Question can be found in the index.php page here: GitHub: using-htmlentities-for-security
- View your index.php file on your localhost in a browser before implementing htmlentities and take a screenshot of the result of entering “<iframe src=”apage.php”></iframe>” in to the Day field.
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
“web-230-072-using-htmlentities-for-security-before.jpg”
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
- View your index.php file on your localhost in a browser after implementing htmlentities and take a screenshot of the result of entering “<iframe src=”apage.php”></iframe>” in to the Day field.
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
“web-230-072-using-htmlentities-for-security-after.jpg”
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
Extra Credit
- Add htmlentities to form submission.
- Make the day field required and added HTML5 validation to check that only letters have been entered with a minimum of two.
- Make the date field required and added HTML5 validation to check that only numbers, no zeros, have been entered with a minimum of one.
- Make the year field required and added HTML5 validation to check that only numbers, no zeros in the beginning, have been entered with a minimum of one.
- View your extra-credit.php file on your localhost in a browser and take a screenshot of it.
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
“web-230-069-working-with-forms-xtra-credit.jpg”
- Save the screenshot to the “series/using-htmlentities-for-security” folder using the file name
Submitting Assignment:
Save folders and file named “series/using-htmlentities-for-security/” in your GitHub “WEB-230-Assignments” repository and submit a link to the “series/using-htmlentities-for-security/” folder in your repository.
Your submission should look similar to the following:
GitHub Repository for: series/using-htmlentities-for-security