4WebHelp
 FAQ  •  Search  •  User Groups  •  Forum Admins  •  Smilies List  •  Statistics  •  Rules   •  Login   •  Register
Toggle Navigation Menu

 PLEASE HELP-XHTML PROBLEMS!~
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic
Author Message
shelly121
Junior WebHelper
Junior WebHelper


Joined: 15 Feb 2005
Posts: 1
Location: shropshire,uk

PostPosted: Tue Feb 15, 2005 12:39 pm (19 years, 2 months ago) Reply with QuoteBack to Top

can any1 help-nt very gud at xhtml bt have 2 do it 4 a uni assignment. i have tryd to create a "print stylesheet" so that when the user prints the page it doesnt show all the colors etc, and i wanted it so that the writing is after the buttons only WHEN PRINTED. as at the mo-the writing is alongside the buttons and goes off the page when printed. heres my stylesheet so far. i have tryd changin the IDs but it stil dont seem to have chnged nethin Embarassed !!!:

Quote:

body {
background: white;
font-size: 12pt;
}
#nav1 #navbar {
display: top;
}
div#class {
width: auto;
margin: 0 5%;
padding: 0;
border: 0;
float: none !important;
color: black;
background: transparent none;
}
div#navbar {
margin-left: 10%;
}
a:link, a:visited {
color: #520;
background: transparent;
font-weight: bold;
text-decoration: underline;
}
#content a:link:after, #content a:visited:after {
content: " (" attr(href) ") ";
font-size: 90%;
}

and heres my actual xhtml for tthe homepage-i have deleted stuff in the paragraphs incase ur wondering y they only have "...."!!
Quote:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>My Homepage</title>
<link rel="stylesheet" href="teststyle.css" />
<link rel="stylesheet"
type="text/css"
media="print" href="print.css" />

</head>
<body>

<div class="head"><h1>.....</h1></div>
<div class="nav1">
<ul>
<li><a href="http://validator.w3.org/check?uri=referer"><img
src="http://www.w3.org/Icons/valid-xhtml10"
alt="Valid XHTML 1.0!" height="31" width="88" /></a></li>
<li><a href="http://jigsaw.w3.org/css-validator/validator"><img src="CSS.bmp" alt="css validated!" /></a></li>
</ul></div>
<div class="navbar"><br /><br /><br /><br /><br />
<ul>
<li><a href="About Me.htm" accesskey="a"> <em>A</em>bout Me!</a></li>
<li><a href="MyTown.htm" accesskey="m"> <em>M</em>y Town </a></li>
<li><a href="pets.htm" accesskey="p"> My <em>P</em>et</a></li>
<li><a href="form.htm" accesskey="c"> <em>C</em>ontact Me</a></li>
</ul>
</div>

<!-- Main content -->
<div class="main">
<p>Welcome to my Homepage</p>

<p>.... </p>

<p>...</p>
<br /><br /><br />
<center><img id="plant" src="plant.jpg" alt="plant" width="150" height="105"border="3" /></center>
<br /><br />
<hr />
<center>
<address></address>
<address> England.</address></center><br /><br /><br /></div>
<div id="navcontainer2">
<ul>
<li><a href="form.htm" accesskey="c"><em>C</em>ontact Me</a></li>
<li><a href="About Me.htm" accesskey="a"> <em>A</em>bout Me!</a></li>
<li><a href="MyTown.htm" accesskey="m"> <em>M</em>y Town </a></li>
</ul>
</div>
</body>
</html>
[/quote]
OfflineView User's ProfileFind all posts by shelly121Send Personal Message
Robert Wellock
WebHelper
WebHelper


Joined: 18 Jan 2002
Posts: 61
Location: Yorkshire - UK

PostPosted: Thu Feb 17, 2005 10:30 am (19 years, 2 months ago) Reply with QuoteBack to Top

It has very little to do with XHTML this is a CSS question though it doesn't help when the XHTML is malformed.

Also the following is nonsense: #nav1 #navbar {display: top;}

It looks like you've made a complete mess of the CSS anyway I assume you meant you just wanted the URI string to appear after the W3C Icons only:

Code:
.nav1 a:link:after , .nav1 a:visited:after {
           content : " (" attr(href) ") ";
           font-size : 90%;
      }


Personally I would have used id values remember /* are your friend */ use them when creating CSS to castrate other CSS when testing for errors.

Most of that CSS sheet has absolutely nothing to do with the XHTML sample you posted.

Since it is your coursework that is all I am prepared to do, anything more would be considered cheating.

________________________________
};-) http://www.xhtmlcoder.com/
OfflineView User's ProfileFind all posts by Robert WellockSend Personal MessageVisit Poster's Website
Display posts from previous:      
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic


 Jump to:   




You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot edit your posts in this forum.
You cannot delete your posts in this forum.
You cannot vote in polls in this forum.


Page generation time: 0.197571 seconds :: 18 queries executed :: All Times are GMT
Powered by phpBB 2.0 © 2001, 2002 phpBB Group :: Based on an FI Theme