質問

カスタムマセッタページにいくつかのカスタムスタイルシートを使用していますが、それらがどの順序でレンダリングされているかに重要です。最初のものでは、次のようなAfterプロパティを使用します。

<SharePoint:CssRegistration runat="server" ID="Custom1" Name="/_layouts/15/Custom1.css" After="corev15.css" />
.

しかし私のカスタムスタイルシートでもこれをすることはできますか?私はこれの行に沿って何かが欲しい:

<SharePoint:CssRegistration runat="server" ID="Custom2" Name="/_layouts/15/Custom2.css" After="Custom1.css" />
.

しかし、これを書くだけではないようです、彼らはランダムな順序で挿入され、時には正しい順序ではありません。私は「後」で別の道を使うか、それはできませんか?

答えのために感謝します!

役に立ちましたか?

解決

Try adding the path, as you have done in Name also, in After. Or since you have the css files directly in the 15, remove the path from the Name property.

First option:

<SharePoint:CssRegistration runat="server" ID="Custom2" Name="/_layouts/15/Custom2.css" After="/_layouts/15/Custom1.css" />

Second option

<SharePoint:CssRegistration runat="server" ID="Custom2" Name="Custom2.css" After="Custom1.css" />
ライセンス: CC-BY-SA帰属
所属していません sharepoint.stackexchange
scroll top