Sample questions

  1. Write php and asp/JavaScript versions of a simple form plus handler. For example, create (in html) the following form:

    The dropdown selection menu should have at least 3 specific cities.
    Create in php and in asp/JavaScript, a handler that will say:

    Thank you, name entered.
    You brought number ticket(s) to destination name.


    Write the php and asp versions to make the correct choice for the above example.

    Thank you, name entered. You brought a ticket to destination name.

    or

    Thank you, name entered. You brought number tickets to destination name.

  2. Write a regular expression and the php and asp/Javascript code to verify the zipcode given in the previous example.
  3. Write a regular expression to accept "United States" or "United States of America" or "USA" or "U.S.A."
  4. Describe 3 differences between php and asp/JavaScript. More difficult version: describe 3 differences between php and asp/JavaScript NOT demonstrated by the coding example.
  5. Describe a suitable database and draw the entity-relationship diagram for a car rental company. You would have the following tables: car models (name, description, cost per day and cost per week, number available), cars (car model name, vin number, status), current customers (name, credit card, expected time back, vin number).
  6. Produce a process diagram for the car rental company. Include a process for a clerk to setup a rental; an company employee to mark a car as returned and give the customer a bill; a company employee to find out what cars need to be cleaned and refueled.
  7. (Open-ended version of prior question) Describe using an ER diagram a database for employee information for a company.
  8. (Open-ended version of prior question) Produce a process for the employee database. Include processes for employees and people in the Human Resources.
  9. Write php or asp/JavaScript code for a loop that will output to the browser N copies of the image in the file bird.gif where N is kept in a variable.
  10. Write php or asp/JavaScript code for an if/else statement.
  11. Write a SQL query that will produce a recordset holding the records (all fields) from a database table titles in which the price field is less than 50.
  12. Write a SQL query that will produce a recordset holding the title_id, title, and price fields for all records from a database table titles in which the category is equal to 'fiction'.