2009-02-23 85 views
2

我正嘗試在默認母版頁上啓用搜索欄。在母版頁的源代碼中有以下內容:默認母版頁上的SharePoint搜索

<asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server"> 
<SharePoint:DelegateControl runat="server" ControlId="SmallSearchInputBox"/> 
</asp:ContentPlaceHolder> 

在設計模式頁面的呈現中,它表示[DelegateControl]。當我發佈這個頁面時,我沒有看到一個搜索框,我什麼都看不到......有人能指示我如何在默認母版頁上啓用搜索,謝謝。

回答

0

你從網站功能激活「的Office SharePoint Server標準版網站集功能」?

2

我有完全相同的問題,但最終找到了一個非常簡單的解決方案。你只需要確保你的asp:ContentPlaceHolder在一個html表單中。我不清楚爲什麼會出現這種情況,只是簡單地將您的代碼更改爲

<form id="Form1" runat="server"> 
<asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server"> 
    <SharePoint:DelegateControl runat="server" ControlId="SmallSearchInputBox"/> 
</asp:ContentPlaceHolder> 
</form> 

應該解決問題。

我發現這很簡單application.master頁:http://blogs.microsoft.co.il/blogs/justguy/archive/2008/08/31/empty-application-master.aspx

當搜索框使用這個簡單的母版頁的工作,我能夠追蹤問題並找到所需要的元素。

+0

輝煌,這對我很有用!有人應該設置這是一個正確的解決方案pronto:D – soniiic 2010-03-26 16:51:42