Errata

Learning PHP, MySQL & JavaScript

Errata for Learning PHP, MySQL & JavaScript

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

Color Key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted by Date submitted
Printed Page Entirety of Chapter 23 - jQuery Mobile
Entire chapter 23

The entire Chapter 23 is obsolete. jQuery Mobile has been deprecated and previous functionality is now included with jQuery Core. The library was deprecated as of Oct 27, 2021. See the announcement here - https://blog.jquerymobile.com/2021/10/07/jquery-maintainers-continue-modernization-initiative-with-deprecation-of-jquery-mobile/

Dave Anderson  Apr 03, 2022 
Page pp 564-565
Example 22-26 and 22-27

The two examples 22-26 and 22-27 (also included as jqueryasyncget.html and jqueryasyncpost.html) both try to retrieve a URL shown as "amazon.com/gp/aw."

The amazon.com web server does not recognize this as anything that will display and returns with a message "We apologize for the inconvenience. An error occurred when we tried to process your request."

A much better result is obtained by simply changing the url to "amazon.com" without the trailing /gp/aw.

Note from the Author or Editor:
Try using the Yahoo Mobile site instead as the Amazon one has changed. Replace 'amazon.com/gp/aw' with 'mobile.yahoo.com'.

Dave Anderson  Apr 03, 2022 
PDF Page 54
Next to the crow image

From the book: "The main two things you have to remember about constants are that they must not be prefaced with a $ (unlike regular variables) and that you can define them only using the define function."

Actually, there's another way to define a constant, the JavaScript way:
const PATH = "/var/www/htdocs/";

Charles  Oct 18, 2023 
Printed Page 271-276
Examples 11-16, 11-17, 11-20, 11-21

Additional uses of "get_magic_quotes_gpc( )" function as part of the author's function "mysql_fix_string( )".

See https://www.php.net/manual/en/function.get-magic-quotes-gpc.php for the note about function deprecation and removal.

Dave Anderson  Feb 09, 2022 
Printed Page 272
1st paragraph

The entire paragraph introducing example 11-17 is incorrect. The PHP function get_magic_quotes_gpc does NOT return true in modern versions of PHP. This function was deprecated as of 7.4.0 (released Nov 28, 2019) and was totally removed as of version 8.0.0. As a minimum, the paragraph should be reworded to account for the removal of this function from PHP. An alternate solution should also be presented.

See the PHP document reference here - https://www.php.net/manual/en/function.get-magic-quotes-gpc.php

Dave Anderson  Feb 10, 2022 
Printed Page 274-275, 308-309
3rd para, example 11-19, example 13-3

If you are using bindParam(), you do not also pass an array to execute(). The paragraph should be changed and the argument to execute() in the examples should be removed.

Scott Ballantyne  Mar 11, 2022