Friday, May 21, 2010

Questions

1) Why doesn't it work to put the "require" statement in header_inc instead of in the config area of each page? I get an error that says get_header() is undefined.

2) Same question for $PageTitle.

3) Same question for $sql that is needed on every page (like a universal menu that appears on each page referencing database items).

4) How do I build my own "if" statements referencing data in the database? ie - if ['Genre'] == Short Story, then display ['Title']...where Genre and Title are database fields.

5) What statements, definitions, variables etc. are absolutely required to make a successful reference to the database? [I am thinking a neat list/diagram would make this much clearer]

5) Why is the $ dropped when referencing variables/properties defined within a class?

6) Is the difference between __construct() and the method just that the method is conditional and __construct() happens no matter what?

7) What is the difference between $selSQL and $SQL?

8) Can I delete the .TGZ file for A7 once it is unpacked?

9) There was mention of a trick that helps to not need an index file in every folder to prevent directory browsing - will this be discussed in class? (I think it is ht_access.)

10) How do I know when to use var, private, or public when defining a property within a class?(The Classes/Paging Lesson example for extending a class uses var, but when the parent was created private and public were used instead. While I understand that a public property is available outside of the class and private is not, I don't understand why var is used in the child.)

11) In the Class Classes/Paging Lesson example for extending a class the variable/property $is_price_negotiable is created but not defined and then passed through the method. Why couldn't the previously created $negotiable_price just be set to TRUE? Why is it necessary to create a new variable or property?

12) If the property is created in the class and not defined, is it defined later or was it already defined somewhere else? How is it stored (ie-in the mysql database?)? Is the lesson automobile example envisioning a form that the enduser fills out or are there dropdown menus with values for these properties? What is the context of the automobile example and what might the interface and output look like?

13) Should every class be defined in separate _inc.php document like Pager_inc.php? Would you ever define in config?

No comments:

Post a Comment