IS448exam3

Card Set Information

Author:
tttran1
ID:
153231
Filename:
IS448exam3
Updated:
2012-05-10 06:51:59
Tags:
is448 webdesign exam3
Folders:

Description:
exam3 for is447
Show Answers:

Home > Flashcards > Print Preview

The flashcards below were created by user tttran1 on FreezingBlue Flashcards. What would you like to do?


  1. A variable defined in a PHP function, by default, is local to the function.
    true
  2. In PHP, there are two types of arrays: numerically indexed arrays and arrays indexed by user-specified strings.
    true
  3. Strings in PHP can be enclosed only in double quotes.
    false
  4. The $_GET array is a pre-defined array in PHP that can be used to get the values entered by a user in an HTML form, provided the form sends the data by using the HTTP GET method.
    true
  5. When we want an HTML form to send data to a PHP program, we should set the action attribute of the form tag to point to the PHP program.
    true
  6. In PHP, there are two types of arrays: numerically indexed arrays and arrays indexed by user-specified strings.
    true
  7. It is possible to convert an array into a string and a string into an array using pre-defined PHP functions.
    true
  8. All variable names in PHP must start with the $ symbol
    true
  9. The ksort function, sorts an array by its values.
    false
  10. Actual parameters is the name given to parameters that are in the call to a function.
    true
  11. The fgetc function returns a character from the file that is being read.
    true
  12. The preg_split function matches a given pattern with a string.
    false
  13. The fopen function returns a file handle for accessing a file.
    true
  14. The flock function should be used to avoid concurrency issues during file read and write.
    true
  15. A session is the time span during which a browser interacts with a particular web server.
    true
  16. HTTP is a stateful protocol, i.e., it stores information about a session that is available to a subsequent session.
    false
  17. Cookies store information about sessions on the browser machine itself.
    true
  18. At the time of creation, a cookie is assigned a lifetime beyond which, the cookie is deleted from the browser host machine.
    true
  19. The setcookie function is used to create a cookie in PHP.
    true
  20. The $_COOKIES array is an implicit array maintained by PHP that holds cookie names as keys and cookie values as values.
    true
  21. In this URL, which of the following are the query-string parameter-names.http://www.simpleforms.com/test.php?lastname=john&firstname=henry&encoding=utf-8&interests=java
    lastname, firstname, encoding, interests
  22. In synchronous communication, a user can keep interacting with the page while data loads.
    false
  23. Scriptaculous is another JavaScript library, built on top of Prototype.
    true
  24. A Javascript framework is a collection of Javascript libraries that allow for easy Javascript development
    true
  25. In Prototype's Ajax.request model, the onFailure option can be set to invoke a Javascript function when the Ajax request is unsuccessful.
    true
  26. In Scriptaculous, Autocompleter.Local allows passing choices for auto-complete as a local array, whereas Ajax.Autocompleter allows passing a URL that fetches the auto-complete choices.
    true
  27. When using Prototype's Ajax.Request object you still have to explicitly set the onreadystatechange property to an event handler
    false
  28. Ajax stands for Asynchronous Java and XML
    false
  29. With Ajax, small parts of the page can be dynamically updated without disturbing the user experience.
    true
  30. The core Javascript object that makes Ajax possible, the XMLHttpRequest object, works in Internet Explorer 6.
    false
  31. MySQL is the name of a popular open source database software.
    true
  32. The Update SQL query is used to select information from a database table.
    false
  33. In a three-tier web architecture, the web server sits between a client and a database system.
    true
  34. The rows of a table in a relation database are referred to as attributes.
    false
  35. SQL is a standardized language for manipulating and querying relational databases
    true
  36. The mysql_connect function is used to establish a connection between the PHP page and the database system.
    true
  37. MySQL operations in PHP are requested through the mysql_query function.
    true
  38. HTML Injection is a flaw where a user is able inject arbitrary HTML code into a web page.
    true
  39. The PHP function htmlspecialchars can be used to prevent HTML Injection attacks.
    true
  40. To prevent SQL Injection attacks, characters such as the single quote and the double quote should be filtered out from any input that comes from the user.
    true
  41. to prevent SQL injection use what?
    • Filter out character like single quote, double quote, slash, back slash, semi colon, extended character like NULL, carry return, new line, etc, in all strings from:- Input from users- Parameters from URL- Values from cookie
    • use mysql_real_escape_string
    • example: $username = mysql_real_escape_string ($_POST['username']);
  42. to prevent HTML injection use what?
    • Convert < > to &lt; &gt; or
    • htmlspecialchars
    • example: $username = htmlspecialchars($_GET[“name"]);
  43. Two-tier architecture
    • Client connects to the database to get information
    • Server or client performs computations and user interactions
  44. Three-tier architecture
    • Web server with applications sits between a browser and the database system
    • The web server accesses the database and carries out computations and deals with user interaction
  45. rows in relation tables are:
    entities
  46. SQL is
    • most popular free database system
    • SQL is a standardized language for manipulating and querying relational databases
  47. The mysql_connect function
    • First First parameter is M SQL ser er host parameter is MySQL server host
    • Second parameter is the MySQL username
    • Third parameter is the password
    • Returns false if it fails
  48. The mysql_close function
    close mysql
  49. mysql_select
    selecting a database
  50. mysql_query
    • Takes a string parameter with an SQL query
    • Returns a data structure that is used to identify data that resulted from query
  51. mysql_num_rows
    gives the number of rows returned for query

What would you like to do?

Home > Flashcards > Print Preview