Forum : browser compatability
Brief description  about Online courses   join in Online courses
View kaushik  n 's Profile

browser compatability

please check this code this is one of the asignment i have done on fonts and div tags. try this code in different browsers like explorer8,opera10,firefox and google chrome. u will find this differently.why is it so???
the code is...


<html>
<! margin: is mainly used to go away from the border layout.it is the exact distance away from the original distance,where as padding is the distance between the margins of the div tags>
<head>
<title>this is eight'th assignment</title>
<style type="text/css">
body
{
background-color:orange;
margin:10px;
}
#first
{
width:1150px;
height:550px;
border:1px solid brown;
background-color:FF8080;
padding:2px;
margin-left:60px;

}

.logo
{
widht:1050px;
height:150px;
border:1px solid #BAA6C6;
background-image:url("images/silicon.jpg");
background-attachment:fixed;
background-color:cyan;
padding:1px;

}
#top
{
width:1123px;
height:12px;
border:1px solid cyan;
background-color:#9E96CB;
padding:9px;
font-family:cosmicsans;
font-size:18px;
color:cyan;
float:left;
}

#left
{

width:950px;
height:500px;
border:1px solid #60F0DE;
background-color:#DDE9F0;
color:maroon;
margin-bottom:350px;
font-family:cosmicsans;
font-size:22px;
font-style:italic;
font-weight:stronger;
margin-left:70px;
padding-top:10px;
margin-bottom:1px;

}
#left1
{
width:250px;
height:750px;
border:1px solid cyan;
background-color:white;
font-size:19px;
font-style:italic;
padding-top:00px;
padding-right:40px;
float:right;
}
#ad
{
width:150px;
height:150px;
border:2px solid cyan;
margin-left:800px;
margin-bottom:500px;
float:center;

margin-top:10px;
}
.red
{
color:green;
font-family:times roman;
font-size:16;
font-weight:bold;
font-style:italic
}
a:link {

text-decoration:blur;
}

a:visited {
color:#990000;
text-decoration: blur;
}

a:hover {
color:pink;
text-decoration: blur;
}

a:active {
text-decoration: blur;
}
#footer
{
border: 1px solid cyan;
font-family:cosmicsans;
margin-top:10px;
background-color:brown;
color:pink;
font-family:cosmicsans;
}

</style>
<body>
<div id="first">
<div class="logo">
<div id="top">
<a href="/home.html"><b>HOME|</b></a>
<a href="/about.html"><b>ABOUT|</b></a>
<a href="/blog.html"><b>BLOG|</b></a>
<a href="/support.html"><b>SUPPORT|</b></a>
<a href="/videos.html"><b>VIDEOS|</b></a>
<a href="/news.html"><b>NEWS|</b></a>
<a href="/more.html"><b>MORE|</b></a>
<a href="/tech.html"><b>TECH|</b></a>
</div></div>
<div id="left"><p><u> This is a demo text</u>.Together, the Himalayan mountain system is the
planet's highest and home to the world's highest peaks, the Eight-thousanders, which
include Mount Everest and K2.To comprehend the enormous scale of this mountain range
, consider that Aconcagua, inthe Andes, at 6,962 metres (22,841 ft) is the highest peak
outside Asia, whereas the Himalayan system includes over 100 mountains exceeding
7,200 m (23,622 ft).
<u><span class="red">Lowland forests
</span></u>
On the Indo-Gangetic plain at the base of the mountains, an alluvial plain drained by the
Indus and Ganga-Brahmaputra river systems, vegetation varies from west to east with
rainfall. The xeric Northwestern thorn scrub forests occupy the plains of Pakistan and
the Indian Punjab. Further east lie the Upper Gangetic plains moist deciduous forests
of Uttarakhand and Uttar Pradesh and Lower Gangetic plains moist deciduous forests of
Bihar and West Bengal. These are monsoon forests, with drought-deciduous trees that
lose their leaves during the dry season. The moister Brahmaputra Valley semi-evergreen
forests occupy the plains of Assam.
The Terai belt<br>Shiwalik Hills

</p>
<div id="left1"><br><img src="images/1.jpg"><br><br>
<img src="images/2.jpg"><br><br><img src="images/3.jpg"><br><br><img src="images/4.jpg"><br><span class="red">all the images are of himalayas which are spread around many countries</span><br>
</div><p align="left">Also called Churia or Margalla Hills, Sivalik Hills is an intermittent
outermost range of foothills extending across the Himalayan region through
Pakistan, India, Nepal and Bhutan.many sub-ranges. Summits are generally 600 to 1,200 metres (2,000 to 3,900 ft).<br>
Steeper southern slopes form along a fault zone called Himalayan Frontal Thrust (HFT); northern slopes are gentler.<br>
Permeable conglomerates and other rocks allow rainwater to percolate downslope into the Bhabhar and Terai, supporting<br>
only scrubby forests upslope. The Himalayan subtropical pine and broadleaf forests continue here.<br>Several places in the Himalaya are of religious significance in Hinduism and Buddhism. In Hinduism, the Himalaya have also been personified as the god Himavat, the father of Shiva's consort, Parvati.

Some of the important religious places in the Himalayas are:-

* Haridwar, the place where the river Ganga enters the plains.
* Badrinath, a temple dedicated to Vishnu.
* Kedarnath, where one of the 12 Jyotirlingas is located.
* Gaumukh, the source of the Bhagirathi (and hence, by extension, the Ganga), located a few miles above the town of Gangotri.
* Devprayag, where the Alaknanda and Bhagirathi merge to form the Ganga.
* Rishikesh, has a temple of Lakshmana.
* Mount Kailash, a 6,638 m high peak which is the abode of the Hindu Gods Shiva and Uma and is also venerated by Buddhists. The peak is forbidden to climb, it is so sacred it is circled at its base. Lake Manasarowar lies at the base of Mount Kailash, and is the source of the Brahmaputra.
* Amarnath, has a natural Shiva linga of ice which forms for a few weeks each year. Thousands of people visit this cave during these few weeks.
* The Vaishno Devi is a popular shrine among Durga devotees.
* Sri Hemkund Sahib - Sikh gurudwara where Guru Gobind Singh is claimed to have meditated and achieved enlightenment in a previous incarnation.

In addition to the above, a number of Tibetan Buddhist sites are situated in the Himalaya, including the residence of the Dalai Lama. There were over 6,000 monasteries in Tibet.[13] The Tibetan Muslims had their own mosques in Lhasa and Shigatse.[14]

The following mystic entities are associated with the Himalayas:

* The Yeti is one of the most famous creatures in cryptozoology. It is a large primate-like creature that is supposed to live in the Himalaya. Most mainstream scientists and experts consider current evidence of the Yeti's existence unpersuasive, and the result of hoaxes, legend or misidentification of mundane creatures.
* Shambhala is a mystical city with various legends associated with it, it is one of twenty-four Himalayan hidden realms, or beyul, in Vajrayana Buddhism.[15] While some legends consider it to be a real city where secret Buddhist doctrines are being preserved, other legends believe that the city does not physically exist, and can only be reached in the mental realm.
<span class="red"><u>Lesser Himalaya</u><br>


Also called Mahabharat Range</span>,< the Lesser Himalayas is a prominent range 2,000 to 3,000 metres (6,600 to 9,800 ft) high formed along the Main Boundary Thrust fault zone, with a steep southern face and gentler northern slopes. They are nearly continuous except for river gorges, where rivers from to the north gather like candelabra in a handful of places to break through the range.

At these elevations and above the biogeography of the Himalayas is generally divided by the Kali Gandaki Gorge in central Nepal, one of the deepest canyons in the world.

At the middle elevations of the range, the subtropical forests yield to a belt of temperate broadleaf and mixed forests growing between 1,500 and 3,000 metres (4,900 and 9,800 ft), with the western Himalayan broadleaf forests to the west of the Gandaki River, and the eastern Himalayan broadleaf forests to the east. The western broadleaf forests stretch from the Kashmir Valley, across Himachal Pradesh and Uttarakhand, and through western Nepal. The eastern broadleaf forests stretch across eastern Nepal, through Sikkim and Bhutan, and through much of Arunachal Pradesh.
MidlandsGreater Himalaya

North of the Main Central Thrust, the highest ranges rise abruptly as much as 4,000 metres (13,000 ft) into the realm of perpetual snow and ice. As the Himalayan system becomes wider from east to west, the number of parallel high ranges increases. For example, Kagmara and Kanjiroba ranges both reach well over 6,000 metres (20,000 ft) north of the Dhaulagiri Himalaya in central Nepal.

Montane grasslands and shrublands grow above treeline. The northwestern Himalayan alpine shrub and meadows are found in the high elevations of northern Pakistan, Jammu and Kashmir, and Himachal Pradesh. To the east, the western Himalayan alpine shrub and meadows cover extensive areas along the Tibetan border with Uttarakhand and western Nepal. The eastern Himalayan alpine shrub and meadows grow above the eastern and northeastern subalpine conifer forests, along the Tibetan border with eastern Nepal, Sikkim, Bhutan, and Arunachal Pradesh. The shrublands are composed of junipers as well as a wide variety of rhododendrons. They also possess a remarkable variety of wildflowers: Valley of Flowers National Park in the western Himalayan alpine shrub and meadows contains hundreds of species. The upper limit of the grasslands increases from west to east, rising from 3,500 metres (11,500 ft) to 5,500 metres (18,000 ft). The grasslands are the summer habitat of the endangered snow leopard (Uncia uncia).
Trans-Himalaya</p>
<div id="ad"> your ad goes here.</div>
</div><div id="footer" align="right"><p align="center"><marquee align="right">accepted by the copyrightlaws.</marquee></p></div>




</body>
</head>
</html>



Asked by kaushik n | May 22, 2010 |  Reply now
Replies (1)
View teacher siliconindia 's Profile
Hi

<link href="homeoutside/formozilla.css" rel="stylesheet" type="text/css" />
<link href="homeoutside/forie.css" rel="stylesheet" type="text/css" />
<link href="homeoutside/forie7new.css" rel="stylesheet" type="text/css" />


<!--[if IE 6]>
<link href="homeoutside/forie.css" rel="stylesheet" type="text/css" />
<![endif]-->

<!--[if IE 7]>
<link href="homeoutside/forie7.css" rel="stylesheet" type="text/css" />
<![endif]-->


We use the above code to overcome the browser compatibility issue.

How it works is. We have 3 different style sheets for IE6, IE7 and Mozilla.

First style sheet "formozilla.css" will work as the master style sheet. If you need any changes to be made in the master css file to adjust IE6 or IE7 just add the same id in the css file for IE6 and make the style change there.

So when the browser reads if that browser is IE6 it will compare both the style sheet, master style sheet and the IE6 style sheet. So if the browser find any change in the CSS file for IE6 it will take that particular style.

The beauty is Mozilla's style sheet will work for all other browsers other than IE. But IE6 style sheet wont work for IE 7 also. Hats off to microsoft :-)

May 24, 2010