thesoundsmith Posted March 16, 2013 Share Posted March 16, 2013 I have a subheading on all of my pages that uses a multiplier in each page's style section to indicate how large to make the subhead - if it's long, it needs to be smaller...For some reason I cannot get the page to recognise the style - other pages with identical settings do (and there are still others that do not, but this is the most recent example.) I have cut and pasted from 'working' pages in case there was a typeo, but the inline element is not found. What am I doing wrong? The page I'm looking at is here: http://www.thesoundsmith.com/mr.htm The style info is: #header p#intro { font-size:200%; font-weight:bold;} and the body /header is: <div id="header"> <h1 id="logo-text"><a href="#" title="">Piano Power!</a></h1> <p id="intro"> Live at the Mission Ranch </p><?php require("menu.php"); ?><!--header ends--></div> On many pages this is fine, why not here? Inspector shows the #header #intro is not seen. Thanks for any ideas. Link to comment Share on other sites More sharing options...
Ingolme Posted March 16, 2013 Share Posted March 16, 2013 A syntax error in a previous line has caused the parser to ignore the code that follows it. This line, in particular:#btmpics (position:relative; margin-left:10px;) Link to comment Share on other sites More sharing options...
thesoundsmith Posted March 16, 2013 Author Share Posted March 16, 2013 (edited) Thanks. You are obviously correct, I removed the line to below the #header and it works. But W3C parser doesn't see it as an error, aI guess it's time to hit the books, because I don't understand why it is a syntax error. (Been awhile since I did any significant coding.), Thanks. Edited March 16, 2013 by The Soundsmith Link to comment Share on other sites More sharing options...
Ingolme Posted March 17, 2013 Share Posted March 17, 2013 It's a syntax error because CSS uses curly brackets { } to contain sets of rules. The HTML validator validates HTML, you need a CSS validator to validate CSS. Link to comment Share on other sites More sharing options...
thesoundsmith Posted March 17, 2013 Author Share Posted March 17, 2013 Ahh, I understand. Thank you. I was under the impression that checker did both.. I think it's all working now. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now