Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>The Sharepoint integration in Alfresco makes use of an embedded Jetty server running the Sharepoint server. If you look at the URL that the "Edit Online", it will show a different port number than all Alfresco web pages (7070 by default).</p> <p>I never ran any deep investigation on the subject, but since Sharepoint is a WebDAV-like extension of HTTP, possibly using some special headers or built in browser plugin/feature, in order to create an "Edit online" functionality in your site you just have to offer the same URLs Alfresco creates for online editing, and make sure the user is running IE. This will direct the user to the <a href="http://wiki.alfresco.com/wiki/Vti" rel="nofollow">VTI server</a>, thus almost completely leaving SpringMVC out of the picture (you just have to generate proper URLs).</p> <hr> <p>EDIT: how alfresco generates VTI URLs</p> <p>Have a look at <a href="http://svn.alfresco.com/repos/alfresco-open-mirror/alfresco/HEAD/root/projects/slingshot/source/web/components/documentlibrary/actions.js" rel="nofollow">actions.js</a>, which is actually generating the URLs underlying the Edit Online links in Share. The <code>_launchOnlineEditor</code> method is what handles clicks to those empty links you saw, and it also provides the logic that creates the url:</p> <pre><code> // Ensure we have the record's onlineEditUrl populated if (!Alfresco.util.isValueSet(record.onlineEditUrl)) { var onlineEditUrl = this.doclistMetadata.custom.vtiServer.host + ":" + this.doclistMetadata.custom.vtiServer.port + "/" + $combine("alfresco", loc.site.name, loc.container.name, loc.path, loc.file); if (!(/^(http|https):\/\//).test(onlineEditUrl)) { // VTI server now supports HTTPS directly http://issues.alfresco.com/jira/browse/DOC-227 onlineEditUrl = window.location.protocol + "//" + onlineEditUrl; } record.onlineEditUrl = onlineEditUrl; } </code></pre> <p>if we had e.g.:</p> <pre><code>loc.site.name == mySite loc.container.name == documentLibrary loc.path == /images loc.file == logo.png </code></pre> <p>with default values for the VTI server it would produce the following URL:</p> <pre><code>http://localhost:7070/alfresco/mySite/documentLibrary/images/logo.png </code></pre> <p>If you also continue reading that method, it turns out that I was totally wrong: it's not just simple MS magic that associate Office applications to specific URLs, but rather an <a href="http://msdn.microsoft.com/en-us/library/ms454230.aspx" rel="nofollow">ActiveX control</a> being created on your browser that results in the proper invocation:</p> <pre><code>var controlProgID = "SharePoint.OpenDocuments", //... activeXControl = new ActiveXObject(controlProgID + ".3"); return activeXControl.EditDocument3(window, record.onlineEditUrl, true, appProgID); </code></pre> <p>This should complete the picture of how to create Sharepoint links from your custom applications, pointing to the right location in the Alfresco repository.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload