Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning JavaScript 5th Edition
This is the forum to discuss the Wrox book Beginning JavaScript, 5th Edition by Jeremy McPeak; 978-1-118-90333-9
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning JavaScript 5th Edition section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old April 3rd, 2016, 10:04 AM
Authorized User
Points: 218, Level: 4
Points: 218, Level: 4 Points: 218, Level: 4 Points: 218, Level: 4
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2015
Posts: 46
Thanks: 1
Thanked 0 Times in 0 Posts
Default Ch1

When I open the page in browser the red color not appear to me in Example 1
Code:
<script type="text/javascript">
// script 2
alert("Second script block");
document.background="red";
</script>
Reply With Quote
  #2 (permalink)  
Old April 3rd, 2016, 10:08 AM
Authorized User
Points: 218, Level: 4
Points: 218, Level: 4 Points: 218, Level: 4 Points: 218, Level: 4
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2015
Posts: 46
Thanks: 1
Thanked 0 Times in 0 Posts
Default

Sorry
I fix the problem
I should use bgColor instead of background
But I Have Q:I java Script Case Sensitive
Reply With Quote
  #3 (permalink)  
Old February 4th, 2017, 01:22 PM
Registered User
Points: 3, Level: 1
Points: 3, Level: 1 Points: 3, Level: 1 Points: 3, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2017
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default bgColor is an obsolete attribute in html5

I downloaded ch. 1 of this book in my search for a good book to review JavaScript. It looks like good one, but already in chapter 1 I have come across code that doesn't work for me, because 'bgcolor' has been made obsolete in html5. Why is a new version of a coding book using obsolete code?

BTW, I searched online and found that it should be document.body.style.backgroundColor

I still think this is a great book, and will buy the online version, but this code disappointed me, because I was really depending on something that was up-to-date.
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ch1 P.37 Code Mystery John Moore BOOK: Beginning Android Application Development 3 September 2nd, 2011 04:11 PM
Ch1 multiple username with same email address Albion BOOK: PHP and MySQL: Create-Modify-Reuse ISBN: 978-0-470-19242-9 3 June 6th, 2011 05:01 PM
ch1 userId nativerun BOOK: PHP and MySQL: Create-Modify-Reuse ISBN: 978-0-470-19242-9 3 January 15th, 2010 07:38 AM
Possible Error? - CH1 Regiser.php ArthurDent BOOK: PHP and MySQL: Create-Modify-Reuse ISBN: 978-0-470-19242-9 2 August 12th, 2008 02:50 AM
Ch1, why using CollectionBase class? NewTitle2007 BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 3 August 5th, 2007 06:32 AM



All times are GMT -4. The time now is 08:11 PM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.