Mendez: chaps 23-26 Flashcards
(11 cards)
what is PHP?
hypertext per-processor: was 1st named (PHP) personal home page
how does PHP work and with what?
a (CGI) Common Gateway Interface script that works with the server side as its a server language and not with the browser side of things.
what is a client side language?
a comp. language that works with the browser on the host computer. if host comp. is slow then webpage loads slow.
what is a server side language?
PHP is an example and the language processing occurs on the server side before sending info to the user’s computer. (*code is hidden from users). -reduces workload on users comp.
what is java?
class-based language. -objects divided into classes. can’t have properties added dynamically to classes.
what is java Script?
object-oriented: properties and methods can be added to objects dynamically.
what is progressive enhancement?
when a web pg is built without javaScript then JavaScript is added to enhance and build on the website to make it more appealing.
what are the two php tags and why use one over the other?
long hand:
short hand:
?>
*longhand is best as shorthand needs to be turned ‘on’ on each server.
what are the 3 PHP error types?
Notices: cpde continues to run- undeclared variables.
- Warnings: doesn’t stop running code, points out error in script.
- Errors: code stops running. causes could be - missing semicolons, function, class definitions, etc.
what does the ^ symbol mean in PHP?
^ except. used when telling a function to do something ‘except’ something else.
example: error_notice(E_ALL^E_NOTICE)
* here all errors are shown when script is read except the Notice ones.
what does the | mean in PHP?
means ‘or’ used in PHP functions.
ex.
error_notice(E_WARNING | E_ERROR))