if i am using the css from the root directory as the html page its displayed properly <link href="styles.css" rel="stylesheet" type="text/css" />

but if i put the css file in a folder <link href="CSS/styles.css" rel="stylesheet" type="text/css" />few of the style are not applied to the page

i need to use the same css with the same layout as of HTML page in .aspx page VS2008but when i use it <link href="styles.css" rel="stylesheet" type="text/css" />the whole contents are messed outthe arrangenment of the elemnts are lost

how do i rectify

PaulOB
—
2011-05-31T09:12:07Z —
#2

svibuk said:

i have created a css file & a html file

if i am using the css from the root directory as the html page its displayed properly <link href="styles.css" rel="stylesheet" type="text/css" />

but if i put the css file in a folder <link href="CSS/styles.css" rel="stylesheet" type="text/css" />few of the style are not applied to the page

What do you mean by a few of the styles are not applied?

If some of them are being applied then you must have linked to the file correctly because it would be all or nothing.

Or do you just have some missing background images which is probably because the path to the images would have changed if you have just dumped the css in another directory?

svibuk
—
2011-05-31T09:17:06Z —
#3

i think u r right reg the background images used in CSS will check it out

the main imp issue is usig css with .net ie with .aspx file

wh am i not getting the desired layout

PaulOB
—
2011-05-31T10:00:35Z —
#4

Hi,

Css and html in a sense have nothing to do with how the page was constructed serverside as all we are interested in is what the browser sees. All we need to know about is what you see from "View source" after the page has landed on the browser.

If you view the resulting code above you will see where the css files are linked to and you can check if the path is correct by following them.

If on the other hand you are talking about how to construct asp pages (how to include files in asp etc) then I'll move the thread to the asp forum as that is a different subject altogether.:)

svibuk
—
2011-05-31T10:12:35Z —
#5

i dont want to know how to construct a dot net page

i just want to implement the .css in aspx page

i hvae linked the external css created in the dotnet pagethis is teh same css which i have used in HTML page

even the layout of both HTML page & dotnet page is sameas i have copied the whole HTML tags from html page to the dotnet page insid ethe body tag but still as i said the matter & the contents in teh dot net page is messed up

i hope u understand my issue

or is there a better way i culd explain

in practical there shld not be any change as i have copied the whole body from HTML page to teh dotnet page as it is , still its creating a problemhope u culd help

PaulOB
—
2011-05-31T12:23:50Z —
#6

Do you have the site live so that we could see it somewhere?

Or perhaps posts 2 screenshot showing the two different displays that you are getting. Then run both pages and from view source copy the code from both pages and paste in here.

Without full html and css we are just guessing. It could be something as simple as you not having a doctype in one page or a typo somewhere.