| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
|
|
#1 (permalink) |
|
Senior Member
Join Date: Feb 2003
Location: Manchester
Posts: 991
|
Overwriting a stylesheet
I have a template that imports a stylesheet however I want to overwrite one of the styles on a number of pages. How is this possible? Andrew Parker
--------------------- (Apple PowerBook G4 1.67GHz / 1Gb RAM / OS X / Safari ) |
|
|
|
|
|
#2 (permalink) |
|
Senior Member
Join Date: Feb 2003
Location: Manchester
Posts: 991
|
To elaborate slightly, this it the head of my template - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"><!-- InstanceBegin template="/Templates/school_template.dwt" codeOutsideHTMLIsLocked="false" --> <head> <!-- InstanceBeginEditable name="doctitle" --> <title>The School of Human & Health Sciences -- Applied Childhood Studies</title> <!-- InstanceEndEditable --> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <!--link before import prevents Flash Of Unstyled Content in ie6pc --> <link href="../css/nn4.css" rel="stylesheet" type="text/css" /> <!--link href="css/localnn4.css" rel="stylesheet" type="text/css" /--> <style type="text/css"> <!-- @import url("../css/real.css"); --> </style> <!-- import with quotes and brackets hides real.css from: Netscape 4.x, Win IE 3, Win IE 4, Mac IE 4.01, Mac IE 4.5, Konqueror 2.1.2, Win Amaya 5.1 Sorry, folks! --> <!-- InstanceBeginEditable name="head" --> <!-- Import local css here !! --> <!-- TemplateBeginEditable name="head" --><!-- TemplateEndEditable --><!-- InstanceEndEditable --> <script language="JavaScript" type="text/JavaScript"> var _version = 1.0; </script> <script language="JavaScript1.1" type="text/JavaScript"> _version = 1.1; </script> <script language="JavaScript1.2" type="text/JavaScript"> _version = 1.2; </script> <!-- InstanceBeginEditable name="navigation" --> <script language="JavaScript" type="text/javascript"> <!-- localLookup is a JS variable, works with the separate nav.js to construct the local navigation menus /* The structure of each line, to be added between the curlies, is: { filename_without_the_.htm_extension: ["text to display", "url to link to"] }; (add a comma at the end of every line except the last one). It is assumed that *all* the local files are in the same folder, and no others. */ var localLookup = { about: ["About the Centre", "http://www.hud.ac.uk/hhs/research/acs/about.htm"], projects: ["Current Projects", "http://www.hud.ac.uk/hhs/research/acs/projects.htm"], pub: ["Centre Publications", "http://www.hud.ac.uk/hhs/research/acs/pub.htm"], staff: ["Staff Information", "http://www.hud.ac.uk/hhs/research/acs/staff.htm"], resource: ["Web Resources", "http://www.hud.ac.uk/hhs/research/acs/resource.htm"] }; //--> </script> <!-- TemplateBeginEditable name="scriptlock" --> <!--scriptlock--> <!-- TemplateEndEditable --> <!-- InstanceEndEditable --> </head> Andrew Parker
--------------------- (Apple PowerBook G4 1.67GHz / 1Gb RAM / OS X / Safari ) |
|
|
|
#4 (permalink) |
|
Magazines™
Join Date: Mar 2003
Location: Glasgow..
Posts: 11,340
|
have went to type on three occasions with and answer but somehow they all fail can you use embedded css in #include or define a load of attributes that are not used in main page but are in #include page or just hard code the template for those pages |
|
|
|
#5 (permalink) |
|
I Ain't Losing Any Sleep™
Join Date: Apr 2003
Posts: 5,236
|
Either redefine the style inline or import another style sheet after the first with the style redefined? Does that make sense? CSS's inheritance will take care of the rest. That's fuckin' ingenious, if I understand it correctly. It's a Swiss fuckin' watch.
|
|
|
|
#6 (permalink) |
|
Senior Member
Join Date: Feb 2003
Location: Manchester
Posts: 991
|
Sorry guys..... I knew how to do this but yesterday was a bastard of a day! I'd simply forgotten to add the style type declaration <style type="text/css"> <!-- @import url("../css/acs.css"); --> </style> 'tard! Andrew Parker
--------------------- (Apple PowerBook G4 1.67GHz / 1Gb RAM / OS X / Safari ) |
|
|
|
#7 (permalink) |
|
I Ain't Losing Any Sleep™
Join Date: Apr 2003
Posts: 5,236
|
Yesterday I forgot how to spell 'shone'. It still doesn't look right! That's fuckin' ingenious, if I understand it correctly. It's a Swiss fuckin' watch.
Last edited by smallbeer : 14-08-2003 at 05:36. |
|
![]() |