Test your basic knowledge |

Php Programming Basics

Subject : it-skills
Instructions:
  • Answer 50 questions in 15 minutes.
  • If you are not ready to take this test, you can study here.
  • Match each statement with the correct term.
  • Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.

This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. To assign keys to the values in an array






2. A data structure that can hold a number of items of data of the same type eg. a list of names






3. Besides GET and POST ________ can be used to access data but $_POST and $_GET are more precise and therefore preferable.






4. To include files - _______ will give errors and _________ will terminate execution().






5. Use ______ when a variable contains any amount of variables; in general.






6. Predefined constants such as __LINE__ or __FILE__ or __FUNCTION__ or __CLASS__ and __METHOD__






7. Use _______ for passwords or pages that would not be bookmarked or pages that require security.






8. To find how many substrings are in a string






9. The seven main error reporting constants are: E_NOTICE - E_WARNING - E_PARSE - E_ERROR - E_ALL - _____ - E_DEPRECATED






10. To delete a variable or an element of an array






11. The three types of loops in PHP are: for - while - ____.






12. Used to create a substring (referred to as a token) from a larger string






13. An array whose keys are strings; also known as a hash.






14. Leading 0x: 0x13F or 0xA23






15. Used to check if a variable has a valid numerical value; strings with numerical values pass.






16. To reset an array _______ the array() function to the array






17. To sort the values while maintaining the correlation between each value and its key - in reversed order






18. Tag to end a php script






19. Used to encrypt values - it is a one-way encryption method






20. print $_SERVER will _____ work if you use the print function on arrays.






21. Shorthand used to increment and decrement






22. Control structure that continue exit - they perform specific statements for a determined number of iterations.






23. To sort values of an array in reversed order






24. Use ______ for search engines or catalogued pages or pages that would be bookmarked.






25. Operators used to operate and assign






26. This error refers to a variable with no value.






27. A conditional or loop is a ________________.






28. Tag to begin a php script






29. _________ can be used in conditional statements to set precedence






30. This will show all error reporting except for notice errors.






31. Used to check if a variable has any value (including 0 or FALSE or an empty string).






32. a positive or negative number






33. identity






34. All variables must begin with _________.






35. To refer to an item in an array






36. $_POST and $_GET are ________ variables.






37. To append elements to an array - this will assign item to the next available index; associative arrays get messy.






38. EXtensible Markup Language






39. TRUE or FALSE






40. bitwise XOR






41. To counter htmlentities()






42. Function that contains the highest value that rand() can have randomly






43. Alias of rtrim()






44. Returns a string with backslashes in front of the specified characters






45. Online applications and resources which are available to the general public with very few restrictions






46. To determine the amount of elements in an array






47. To sort the values while maintaining the correlation between each value and its key






48. Search Engine Optimization






49. Used to convert all HTML tags into their entity versions.






50. The four main error types are:Notice - Warning - ________ and Error.