How can I include CSS external file in content page

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sijugeo
    New Member
    • Jul 2007
    • 42

    How can I include CSS external file in content page

    Hi,

    I have a content page which is not in a folder where master page is saved.
    This made the styles not working in that page. How can I include the same css file which is used in the master page for this content page.

    Thanks in advance,
    Siju George
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    You have to specify which folder your CSS file is in.

    For example: if you have a folder called Styles in the root directory that holds all of your external CSS files....and your master page is in the root directory as well you would set the href of the css link to:


    <link href="~/Styles/MyStyle.css" rel="stylesheet " type="text/css" />

    So if your Content page is using a different style sheet than your master page you will have to include that in your content page.

    It should work fine if you include this style in your Master page though....as it should apply also to the content page (since the two of them are compiled together and rendered as one page).

    -Frinny

    Comment

    Working...