Wrox Programmer Forums
|
BOOK: Professional JavaScript for Web Developers 2nd edition ISBN: 9780470227800
This is the forum to discuss the Wrox book Professional JavaScript for Web Developers, 2nd Edition by Nicholas C Zakas; ISBN: 9780470227800
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional JavaScript for Web Developers 2nd edition ISBN: 9780470227800 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 31st, 2010, 07:35 AM
Registered User
 
Join Date: Oct 2010
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ch10 P308 looks wrong..

Why is script.text set to quoted code?
Surely the double quotes are incorrect in the catch block.

You have
var code = "function sayHi() {alert('hi');}";

Then later script.text = "code";

surely
script.text = code is the solution.
 
Old November 1st, 2010, 06:20 PM
nzakas's Avatar
Wrox Author
 
Join Date: Dec 2004
Posts: 217
Thanks: 0
Thanked 5 Times in 5 Posts
Default

code should not be quoted. This issue was reported on the errata page:

http://www.wrox.com/WileyCDA/WroxTit...Cd-ERRATA.html
__________________
Nicholas C. Zakas
Author, Professional JavaScript for Web Developers (ISBN 0764579088)
http://www.nczonline.net/





Similar Threads
Thread Thread Starter Forum Replies Last Post
Is this worded wrong or am I reading wrong? notig BOOK: Beginning Visual C# 2010 1 September 25th, 2010 01:51 PM
Errors in the book @ ch10 freezotic BOOK: Beginning Java 2 0 March 26th, 2004 04:54 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.