2011-02-25 238 views

回答

1

什麼是'快捷菜單'?是否意味着列表項上下文菜單或其他東西?你可以張貼截圖嗎?

  • 有兩種類型的鏈接使用。

  • 正常的HTML定位點 - 點擊時可以按住CTRL鍵。

JavaScript鏈接(菜單等)的CTRL鍵不起作用。如果你與編輯/查看的形式工作,那麼這可能會感興趣

特別是尋找在那裏談論改變列表設置>高級設置>對話框這種行爲第二部分

1

這實際上是一個Internet Explorer特定的錯誤。 SharePoint 2010中的導航鏈接是常規鏈接,但鏈接文本週圍有兩個嵌套的範圍標籤。這混淆了IE,它沒有意識到你正在右鍵單擊的文本是一個鏈接,所以沒有給出正確的上下文菜單。如果右鍵單擊鏈接文本的左側(遊標仍應顯示爲「手形」),上下文菜單將按預期顯示。

3

使用JavaScript函數在SharePoint 2010

打開一個新窗口創建函數打開目標窗口,如下面的示例提供。

function load_url(externallink) 
{ 
    window.open(externallink,target='_blank') 
} 

將在JavaScript函數load_url文件

點擊網站操作,選擇管理內容和結構。 假設您想要更改頁面中的鏈接 http://someserver/sites/Dev/Help/HelpLinks/AllItems.aspx

然後在子站點幫助中選擇名爲HelpLinks的列表。 Dev將成爲最頂級的節點(站點)。幫助將是一個子網站和內部幫助你可以找到按名稱列表HelpLinks

  1. 頁面中所有的鏈接,他們的名稱將顯示

  2. 選擇要在新標籤頁,右鍵點擊打開鏈接的標題。

  3. 選擇編輯屬性。然後,在URL字段和調用功能javascript:load_url('http://www.google.co.in');代替http:// www.google.co.in

否則 假設你想改變在下面的網址鏈接。 URL: http:// someserver/sites/Dev/Help/HelpLinks/AllItems.aspx

轉到

  1. 開放鏈接http:// someserver/sites/Dev/Help/HelpLinks/AllItems.aspx

  2. 你會發現列表的列(標題欄,URL欄,摘要等)。

  3. 選擇標題,然後單擊要編輯

  4. 然後在URL字段編輯屬性和調用功能javascript:load_url('http://www.google.co.in');代替http:// www.google.co.in

-1

這個加入的結束鏈接。

#openinnewwindow

例如:http://www.bing.com**#openinnewwindow

0

在SharePoint維基編輯器,你可以單擊「發件人地址」您添加鏈接和鏈接菜單將出現在功能導航欄。在那裏,你可以點擊「在新標籤中打開」這不是新窗口,但它非常簡單。

1

這個答案是這篇文章的概括,而不是我想出了一個答案:http://sharepointsolutions.blogspot.com/2007/09/make-selected-links-in-links-list-open.html

第1步:添加#openinnewwindow您要在新窗口中打開所有超鏈接的結束。

第2步:然後,您需要將後續腳本添加到您的SharePoint頁面。 (!&resoundly調升) - :用於將細節感謝

[script language = "JavaScript"] 
 

 
//add an entry to the _spBodyOnLoadFunctionNames array 
 
//so that our function will run on the pageLoad event 
 
_spBodyOnLoadFunctionNames.push("rewriteLinks"); 
 

 
function rewriteLinks() { 
 
    //create an array to store all the anchor elements in the page 
 
    var anchors = document.getElementsByTagName("a"); 
 

 
    //loop through the array 
 
    for (var x = 0; x < anchors.length; x++) { 
 
    //does this anchor element contain #openinnewwindow? 
 
    if (anchors[x].outerHTML.indexOf('#openinnewwindow') > 0) { 
 
     //store the HTML for this anchor element 
 
     oldText = anchors[x].outerHTML; 
 
     //rewrite the URL to remove our test text and add a target instead 
 
     newText = oldText.replace(/#openinnewwindow/, '" target="_blank'); 
 
     //write the HTML back to the browser 
 
     anchors[x].outerHTML = newText; 
 
    } 
 
    } 
 
} 
 
[/script]

+0

精彩爲我們的偉大工程 – whytheq 2017-12-11 13:18:13

相關問題