在SharePoint MVC应用程序中,我使用以下代码进行chrome Control。
<!-- Chrome control placeholder Options are declared inline. -->
<div
id="chrome_ctrl_container"
data-ms-control="SP.UI.Controls.Navigation"
title="Title of the application"
data-ms-options='{
"appIconUrl" : "Images/Logo.GIF",
"appTitle" : "SharePoint MVC",
"appHelpPageUrl" : "Help.html",
"settingsLinks" : [
{
"linkUrl" : "Account.html",
"displayName" : "Account settings"
},
{
"linkUrl" : "Contact.html",
"displayName" : "Contact us"
}
]
}'>
</div>
我想删除标题和网站图标,以便我可以在sharepoint栏后创建自定义标题。
答案 0 :(得分:1)
根据您要删除的内容,您有一些选项:
data-ms-options
属性中的选项。 data-ms-control
。这将删除导航,您可以替换您想要的任何内容。 参考:How to: Use the client chrome control in apps for SharePoint
答案 1 :(得分:1)
添加以下选项:
&#34; bottomHeaderVisible&#34;:false,
例如,您的代码为:
<!-- Chrome control placeholder Options are declared inline. -->
<div
id="chrome_ctrl_container"
data-ms-control="SP.UI.Controls.Navigation"
title="Title of the application"
data-ms-options='{
"bottomHeaderVisible": false,
"appIconUrl" : "Images/Logo.GIF",
"appTitle" : "SharePoint MVC",
"appHelpPageUrl" : "Help.html",
"settingsLinks" : [
{
"linkUrl" : "Account.html",
"displayName" : "Account settings"
},
{
"linkUrl" : "Contact.html",
"displayName" : "Contact us"
}
]
}'>
</div>