Book description
This updated edition teaches everything you need to know to create effective web applications with the latest features in PHP 5.x. You’ll start with the big picture and then dive into language syntax, programming techniques, and other details, using examples that illustrate both correct usage and common idioms.
If you have a working knowledge of HTML, the authors’ many style tips and practical programming advice will help you become a top-notch PHP programmer.
- Get an overview of what’s possible with PHP programs
- Learn language fundamentals, including data types, variables, operators, and flow control statements
- Understand functions, strings, arrays, and objects
- Apply common web application techniques, such as form processing, data validation, session tracking, and cookies
- Interact with relational databases like MySQL or NoSQL databases such as MongoDB
- Generate dynamic images, create PDF files, and parse XML files
- Learn secure scripts, error handling, performance tuning, and other advanced topics
- Get a quick reference to PHP core functions and standard extensions
Publisher resources
Table of contents
- Programming PHP
- Dedication
- A Note Regarding Supplemental Files
- Foreword
- Preface
- 1. Introduction to PHP
-
2. Language Basics
- Lexical Structure
- Data Types
- Variables
- Expressions and Operators
- Flow-Control Statements
- Including Code
- Embedding PHP in Web Pages
- 3. Functions
-
4. Strings
- Quoting String Constants
- Printing Strings
- Accessing Individual Characters
- Cleaning Strings
- Encoding and Escaping
- Comparing Strings
- Manipulating and Searching Strings
-
Regular Expressions
- The Basics
- Character Classes
- Alternatives
- Repeating Sequences
- Subpatterns
- Delimiters
- Match Behavior
- Character Classes
- Anchors
- Quantifiers and Greed
- Noncapturing Groups
- Backreferences
- Trailing Options
- Inline Options
- Lookahead and Lookbehind
- Cut
- Conditional Expressions
- Functions
- Differences from Perl Regular Expressions
- 5. Arrays
- 6. Objects
- 7. Web Techniques
- 8. Databases
- 9. Graphics
- 10. PDF
- 11. XML
- 12. Security
- 13. Application Techniques
- 14. PHP on Disparate Platforms
- 15. Web Services
- 16. Debugging PHP
- 17. Dates and Times
-
A. Function Reference
- PHP Functions by Category
-
Alphabetical Listing of PHP Functions
- abs
- acos
- acosh
- addcslashes
- addslashes
- array_change_key_case
- array_chunk
- array_combine
- array_count_values
- array_diff
- array_diff_assoc
- array_diff_key
- array_diff_uassoc
- array_diff_ukey
- array_fill
- array_fill_keys
- array_filter
- array_flip
- array_intersect
- array_intersect_assoc
- array_intersect_key
- array_intersect_uassoc
- array_intersect_ukey
- array_key_exists
- array_keys
- array_map
- array_merge
- array_merge_recursive
- array_multisort
- array_pad
- array_pop
- array_product
- array_push
- array_rand
- array_reduce
- array_replace
- array_replace_recursive
- array_reverse
- array_search
- array_shift
- array_slice
- array_splice
- array_sum
- array_udiff
- array_udiff_assoc
- array_udiff_uassoc
- array_uintersect
- array_uintersect_assoc
- array_uintersect_uassoc
- array_unique
- array_unshift
- array_values
- array_walk
- array_walk_recursive
- arsort
- asin
- asinh
- asort
- assert
- assert_options
- atan
- atan2
- atanh
- base_convert
- base64_decode
- base64_encode
- basename
- bin2hex
- bindec
- call_user_func
- call_user_func_array
- ceil
- chdir
- checkdate
- checkdnsrr
- chgrp
- chmod
- chown
- chr
- chroot
- chunk_split
- class_alias
- class_exists
- class_implements
- class_parents
- clearstatcache
- closedir
- closelog
- compact
- connection_aborted
- connection_status
- constant
- convert_cyr_string
- convert_uudecode
- convert_uuencode
- copy
- cos
- cosh
- count
- count_chars
- crc32
- create_function
- crypt
- current
- date
- date_default_timezone_set
- date_default_timezone_get
- date_parse
- date_parse_from_format
- date_sun_info
- date_sunrise
- date_sunset
- debug_backtrace
- debug_print_backtrace
- decbin
- dechex
- decoct
- define
- define_syslog_variables
- defined
- deg2rad
- dir
- dirname
- disk_free_space
- disk_total_space
- each
- echo
- empty
- end
- error_get_last
- error_log
- error_reporting
- escapeshellarg
- escapeshellcmd
- exec
- exp
- explode
- expm1
- extension_loaded
- extract
- fclose
- feof
- fflush
- fgetc
- fgetcsv
- fgets
- fgetss
- file
- file_exists
- fileatime
- filectime
- file_get_contents
- filegroup
- fileinode
- filemtime
- fileowner
- fileperms
- file_put_contents
- filesize
- filetype
- filter_has_var
- filter_id
- filter_input
- filter_input_array
- filter_list
- filter_var
- filter_var_array
- floatval
- flock
- floor
- flush
- fmod
- fnmatch
- fopen
- forward_static_call
- forward_static_call_array
- fpassthru
- fprintf
- fputcsv
- fread
- fscanf
- fseek
- fsockopen
- fstat
- ftell
- ftruncate
- func_get_arg
- func_get_args
- func_num_args
- function_exists
- fwrite
- gc_collect_cycles
- gc_disable
- gc_enable
- gc_enabled
- get_browser
- get_called_class
- get_cfg_var
- get_class
- get_class_methods
- get_class_vars
- get_current_user
- get_declared_classes
- get_declared_interfaces
- get_declared_traits
- get_defined_constants
- get_defined_functions
- get_defined_vars
- get_extension_funcs
- get_headers
- get_html_translation_table
- get_included_files
- get_include_path
- get_loaded_extensions
- get_meta_tags
- getmygid
- getmyuid
- get_object_vars
- get_parent_class
- get_resource_type
- getcwd
- getdate
- getenv
- gethostbyaddr
- gethostbyname
- gethostbynamel
- gethostname
- getlastmod
- getmxrr
- getmyinode
- getmypid
- getopt
- getprotobyname
- getprotobynumber
- getrandmax
- getrusage
- getservbyname
- getservbyport
- gettimeofday
- gettype
- glob
- gmdate
- gmmktime
- gmstrftime
- header
- header_remove
- headers_list
- headers_sent
- hebrev
- hebrevc
- hex2bin
- hexdec
- highlight_file
- highlight_string
- htmlentities
- html_entity_decode
- htmlspecialchars
- htmlspecialchars_decode
- http_build_query
- hypot
- idate
- ignore_user_abort
- implode
- inet_ntop
- inet_pton
- in_array
- ini_get
- ini_get_all
- ini_restore
- ini_set
- interface_exists
- intval
- ip2long
- is_a
- is_array
- is_bool
- is_callable
- is_dir
- is_executable
- is_file
- is_finite
- is_float
- is_infinite
- is_int
- is_link
- is_nan
- is_null
- is_numeric
- is_object
- is_readable
- is_resource
- is_scalar
- is_string
- is_subclass_of
- is_uploaded_file
- is_writable
- isset
- key
- krsort
- ksort
- lcfirst
- lcg_value
- lchgrp
- lchown
- levenshtein
- link
- linkinfo
- list
- localeconv
- localtime
- log
- log10
- log1p
- long2ip
- lstat
- ltrim
- max
- md5
- md5_file
- memory_get_peak_usage
- memory_get_usage
- metaphone
- method_exists
- microtime
- min
- mkdir
- mktime
- money_format
- move_uploaded_file
- mt_getrandmax
- mt_rand
- mt_srand
- natcasesort
- natsort
- next
- nl_langinfo
- nl2br
- number_format
- ob_clean
- ob_end_clean
- ob_end_flush
- ob_flush
- ob_get_clean
- ob_get_contents
- ob_get_flush
- ob_get_length
- ob_get_level
- ob_get_status
- ob_gzhandler
- ob_implicit_flush
- ob_list_handlers
- ob_start
- octdec
- opendir
- openlog
- ord
- output_add_rewrite_var
- output_reset_rewrite_vars
- pack
- parse_ini_file
- parse_ini_string
- parse_str
- parse_url
- passthru
- pathinfo
- pclose
- pfsockopen
- php_ini_loaded_file
- php_ini_scanned_files
- php_logo_guid
- php_sapi_name
- php_strip_whitespace
- php_uname
- phpcredits
- phpinfo
- phpversion
- pi
- popen
- pow
- prev
- print_r
- printf
- proc_close
- proc_get_status
- proc_nice
- proc_open
- proc_terminate
- property_exists
- putenv
- quoted_printable_decode
- quoted_printable_encode
- quotemeta
- rad2deg
- rand
- range
- rawurldecode
- rawurlencode
- readdir
- readfile
- readlink
- realpath
- realpath_cache_get
- realpath_cache_size
- register_shutdown_function
- register_tick_function
- rename
- reset
- restore_error_handler
- restore_exception_handler
- restore_include_path
- rewind
- rewinddir
- rmdir
- round
- rsort
- rtrim
- scandir
- serialize
- set_error_handler
- set_exception_handler
- set_include_path
- set_time_limit
- setcookie
- setlocale
- setrawcookie
- settype
- sha1
- sha1_file
- shell_exec
- shuffle
- similar_text
- sin
- sinh
- sleep
- sort
- soundex
- sprintf
- sqrt
- srand
- sscanf
- stat
- str_getcsv
- str_ireplace
- str_pad
- str_repeat
- str_replace
- str_rot13
- str_shuffle
- str_split
- str_word_count
- strcasecmp
- strcmp
- strcoll
- strcspn
- strftime
- stripcslashes
- stripslashes
- strip_tags
- stripos
- stristr
- strlen
- strnatcasecmp
- strnatcmp
- strncasecmp
- strncmp
- strpbrk
- strpos
- strptime
- strrchr
- strrev
- strripos
- strrpos
- strspn
- strstr
- strtok
- strtolower
- strtotime
- strtoupper
- strtr
- strval
- substr
- substr_compare
- substr_count
- substr_replace
- symlink
- syslog
- system
- sys_getloadavg
- sys_get_temp_dir
- tan
- tanh
- tempnam
- time
- time_nanosleep
- time_sleep_until
- timezone_name_from_abbr
- timezone_version_get
- tmpfile
- token_get_all
- token_name
- touch
- trait_exists
- trigger_error
- trim
- uasort
- ucfirst
- ucwords
- uksort
- umask
- uniqid
- unlink
- unpack
- unregister_tick_function
- unserialize
- unset
- urldecode
- urlencode
- usleep
- usort
- var_dump
- var_export
- version_compare
- vfprintf
- vprintf
- vsprintf
- wordwrap
- zend_logo_guid
- zend_thread_id
- zend_version
- Index
- About the Authors
- Colophon
- Copyright
Product information
- Title: Programming PHP, 3rd Edition
- Author(s):
- Release date: February 2013
- Publisher(s): O'Reilly Media, Inc.
- ISBN: 9781449392772
You might also like
book
Programming PHP, 2nd Edition
Programming PHP, 2nd Edition, is the authoritative guide to PHP 5 and is filled with the …
book
Programming PHP
PHP is a simple yet powerful open-source scripting language for creating dynamic web content. The millions …
book
Core PHP Programming, Third Edition
Core PHP Programming, Third Edition is the authoritative guide to the new PHP 5 for experienced …
book
PHP 5 Power Programming
"This book, written by my colleague, Andi Gutmans, and two very prominent PHP developers, Stig Bakken …