Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8
This is the forum to discuss the Wrox book Beginning ASP.NET 2.0 by Chris Hart, John Kauffman, David Sussman, Chris Ullman; ISBN: 9780764588501
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 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 January 10th, 2008, 12:20 PM
Authorized User
 
Join Date: Sep 2007
Posts: 48
Thanks: 0
Thanked 0 Times in 0 Posts
Default VB: Ch5 p177 Themes in Wrox United

In previous studies on applying styles to HTML using stylesheets, it was clear that while class style rules could be applied to many different elements on a page, an id style rule could only be applied to a single element.
The first paragraph on p177 (below the stylesheet code) says "The #nav definition and the #content definition are used to match all elements on a page with an id set to nav or content respectively, ...". "All elements" seems to imply that any number of elements can use the same id.
Anyone else noticed this?
Can anyone explain this for me?

Richard
Rugeley, UK
WinXP Pro SP2
VBW Express
__________________
Richard
Rugeley, UK
WinXP Pro SP2
VBW Express + SQL Server 2005 Express
 
Old January 10th, 2008, 05:19 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

You're correct. These ID selectors should refer to a single / unique element in a single page. You can have many elements with the same ID in your *site* as long as you have only one of them in each page. E.g. you can repeat an item in every page in your site if you wanted to, but you cannot repeat an item within a page.

Maybe the confusion comes from the fact the example tries to mention both #nav and #content, collectively referred to as elements?

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Wrox United issues shanebbb BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 0 December 2nd, 2008 10:44 AM
Wrox United not working chris31martin BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 2 July 16th, 2008 09:00 AM
VB: Ch5 P157 Try It Out Applying Themes Rich57 BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 1 January 10th, 2008 01:18 PM
Re: Wrox United Logo dotnet411 BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 1 June 10th, 2006 09:46 AM
Wrox United chapter 4 diango BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 4 December 29th, 2005 12:47 PM





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