Where can I add link tags on a page that has a homepage?

When I type it here: -

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">

<link href="Skins/SkinCustom/Editor.Default.css" rel="stylesheet" type="text/css" />

</asp:Content>

He says that Element Link cannot be nested in a div ... how should I link my css files?

+3
source share
2 answers

Add your ContentPlaceHolder to your tag head:

<head>
    <asp:ContentPlaceHolder ID="head" runat="server"></asp:ContentPlaceHolder>
</head>

Then on your content page:

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <link href="Skins/SkinCustom/Editor.Default.css" rel="stylesheet" type="text/css" />
</asp:Content>
+9
source

If your main page does not contain a content placeholder in the section <head>(ed: and you cannot edit it), you might be out of luck.

Look at the source of the homepage and see what other content placeholders are available.

+3
source

Source: https://habr.com/ru/post/1772048/


All Articles