CSS Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignCSS Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old June 22nd, 2004, 10:55 PM
x_solidus_x's Avatar
x_solidus_x x_solidus_x is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 303 x_solidus_x User rank is Private First Class (20 - 50 Reputation Level)x_solidus_x User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 3 Days 14 h 52 m
Reputation Power: 5
applying css and xslt to an xml document

I have a css stylesheet and an xslt stylesheet.
In my xml doc i apply the xslt stylesheet, but how do i also apply the css?

thanks
__________________
That's my $0.02

Reply With Quote
  #2  
Old June 23rd, 2004, 01:35 AM
kk5st's Avatar
kk5st kk5st is offline
Thanks Johnny Hart (BC) R.I.P.
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: May 2003
Location: Dallas
Posts: 4,659 kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level) 
Time spent in forums: 1 Month 3 Days 11 h 50 m 18 sec
Reputation Power: 687
<?xml-stylesheet href="mystyle.css" type="text/css"?>

cheers,

gary
__________________
There are those who manage to build a web site without knowing what they're doing; thereby proving to themselves they do, indeed, know what they're doing.

My html and css workshop, demos and tutorials.
Ask a better question, get a better answer.

Reply With Quote
  #3  
Old June 23rd, 2004, 01:56 AM
1beb's Avatar
1beb 1beb is offline
This tagline is not long enoug
Dev Shed Novice (500 - 999 posts)
 
Join Date: Aug 2003
Location: Toronto, ON Canada! I AM CANADIAN
Posts: 861 1beb User rank is Corporal (100 - 500 Reputation Level)1beb User rank is Corporal (100 - 500 Reputation Level)1beb User rank is Corporal (100 - 500 Reputation Level)1beb User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 2 h 32 m 12 sec
Reputation Power: 10
Send a message via ICQ to 1beb Send a message via AIM to 1beb Send a message via MSN to 1beb Send a message via Yahoo to 1beb
I thought that xslt is to xml, as css is to html? Any suggestions on where one could learn more about xslt?

Reply With Quote
  #4  
Old June 23rd, 2004, 06:07 AM
Akh's Avatar
Akh Akh is offline
|<.+#f@#+.&.|
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Mar 2002
Location: norway
Posts: 2,715 Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level) 
Time spent in forums: 4 Weeks 16 h 43 m 11 sec
Reputation Power: 642
no,
with css you can define the look and layout,
but with xslt you can transform the document, you can prossess the data in the xml-document.

http://www.w3.org/Style/XSL/WhatIsXSL.html

so basicly you should use css when you can,
and xslt when you must, as xslt can be more "heavy" to run.

Reply With Quote
  #5  
Old June 23rd, 2004, 05:02 PM
x_solidus_x's Avatar
x_solidus_x x_solidus_x is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 303 x_solidus_x User rank is Private First Class (20 - 50 Reputation Level)x_solidus_x User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 3 Days 14 h 52 m
Reputation Power: 5
the problem is that my prof gave me **** for using tags like <i></i> and <b></b> and the <font> tag in my xslt document. he said i should use css, but i don't know how to apply the css stylesheet along with the xslt. i tried putting in a <link>, but it didn't work, maybe i put in the wrong thing, can you please check it:

PHP Code:
<xsl:template match="/">
  <
html>
  <
head>
  <
title>Bird Observations</title>
  <
meta name="Content-Style-Type" content="text/css"/>
  <
link href="observations_style.css" rel="stylesheet" type="text/css" media="screen"/>
  </
head>
  <
body>
  <
xsl:apply-templates/>
  </
body>
  </
html>
  </
xsl:template

Reply With Quote
  #6  
Old June 23rd, 2004, 05:41 PM
kk5st's Avatar
kk5st kk5st is offline
Thanks Johnny Hart (BC) R.I.P.
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: May 2003
Location: Dallas
Posts: 4,659 kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level)kk5st User rank is Brigadier General (60000 - 70000 Reputation Level) 
Time spent in forums: 1 Month 3 Days 11 h 50 m 18 sec
Reputation Power: 687
OK, once more. This is from W3Schools;
Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/css" href="cd_catalog.css"?>
<CATALOG>
  <CD>
    <TITLE>Empire Burlesque</TITLE>
    <ARTIST>Bob Dylan</ARTIST> …
For homework, you should read your notes and text, or talk to your TA or classmates. We're not doing you any favors doing it for you.

cheers,

gary

Reply With Quote
  #7  
Old June 24th, 2004, 12:43 PM
x_solidus_x's Avatar
x_solidus_x x_solidus_x is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 303 x_solidus_x User rank is Private First Class (20 - 50 Reputation Level)x_solidus_x User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 3 Days 14 h 52 m
Reputation Power: 5
kk5st, you don't get it.

i know how to attach a css stylesheet to an xml document, i have to attach BOTH a css and an xslt stylesheet to the document.

i tried doing it by putting a <link> tag inside the xslt but it doesn't work, i'm only asking for you to check if my syntax is correct, not to do it for me.

Reply With Quote
  #8  
Old June 24th, 2004, 01:19 PM
Akh's Avatar
Akh Akh is offline
|<.+#f@#+.&.|
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Mar 2002
Location: norway
Posts: 2,715 Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level)Akh User rank is Brigadier General (60000 - 70000 Reputation Level) 
Time spent in forums: 4 Weeks 16 h 43 m 11 sec
Reputation Power: 642
i see nothing wrong with the syntax,
it should work without a problem.

did also tested yours example, the css loaded without a problem

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignCSS Help > applying css and xslt to an xml document


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT