XML Tutorial #4: How to connect an external style sheet to xml

<?xml version=”1.0″ encoding=”ISO-8859-1″?>
<?xml-stylesheet type=”text/css” href=”3.css”?><!–This is how we connect to css file–>
<persion>
<male>
<name>Tanvir</name>
<age>22</age>
<religion>Islam</religion>
</male>
</persion>

 

 

/****************** 3.css **************/

@charset “utf-8″;
/* CSS Document */

persion,male
{
font-family:”Comic Sans MS”, cursive;

}
name
{
display:block;
font-size:24px;
color:#C69;
}
age,religion
{
display:block;
}

Advertisements
By kfelahi Posted in XML

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s