03-16-2009 02:12 PM
04-10-2009 03:04 AM
04-21-2009 06:38 AM
04-21-2009 01:18 PM
$document->addScript($this->profile->share.'/yui/selector/selector-beta-min.jss');
$document->addScript($this->profile->share.'/yui/selector/selector-beta-min.jss');
// Document Preview
$document->addStylesheet($this->profile->share.'/components/preview/preview.css');
$document->addScript($this->profile->share.'/components/preview/preview.js');
$document->addStylesheet($this->profile->share.'/components/preview/full-preview.css');
$document->addScript($this->profile->share.'/components/preview/full-preview.js');
04-21-2009 02:23 PM
$document->addStylesheet($this->profile->share.'/components/preview/web-preview.css');
$document->addScript($this->profile->share.'/components/preview/web-preview.js');
$document->addStylesheet($this->profile->share.'/components/preview/WebPreviewer.css');
<script type="text/javascript">//<![CDATA[
new Alfresco.WebPreview("document-details").setOptions({…
<script type="text/javascript">//<![CDATA[
new Alfresco.WebPreview("document-details").setOptions({
nodeRef: 'workspace://SpacesStore/<?php echo $this->file->uuid ?>',
name: '<?php echo $this->file->name ?>',
icon: '/components/images/generic-file-32.png',
mimeType: '<?php echo $this->file->content_type ?>',
previews: <?php echo json_encode($this->thumbnail->definitions) ?>
}).setMessages(
{"label.currentFrame": "Page <b>{0}<\/b> of <b>{1}<\/b>", "button.next": "Next", "header.previewDocument": "Preview of {0}", "error.contentNotAVM2MovieClip": "The preview cannot be displayed since its not a AVM2 movie clip", "label.noFlash": "To view the preview please download the latest Flash Player from the<br\/> <a href=\"http:\/\/www.adobe.com\/go\/getflashplayer\">Adobe Flash Player Download Center<\/a>.", "label.jumpToPage": "Jump to page:", "label.noPreview": "This document can't be previewed.<br\/>Click <a href=\"{0}\">here<\/a> to download it.", "button.fullPreview": "Full Screen", "message.invalidFrame": "You must enter a frame between {0} and {1}", "error.server": "The preview cannot be displayed due to a server error", "button.previous": "Prev"}
);
//]]></script>
05-14-2009 10:41 AM
the key change is new Alfresco.Preview needs to become "new Alfresco.WebPreview"
05-14-2009 04:27 PM
05-14-2009 05:37 PM
05-14-2009 05:51 PM
05-15-2009 08:40 AM
var so = new deconcept.SWFObject(Alfresco.constants.URL_CONTEXT + "/components/preview/WebPreviewer.swf","WebPreviewer", "100%", "670", "9.0.45");
so.addVariable("fileName", this.options.name);
so.addVariable("paging", previewCtx.paging);
so.addVariable("url", escape(previewCtx.url));
so.addVariable("jsCallback", "Alfresco.util.ComponentManager.find({id:'" + this.id + "'})[0].onWebPreviewerEvent");
so.addParam("allowScriptAccess", "always");
//so.addParam("allowScriptAccess", "sameDomain");
so.addParam("allowFullScreen", "true");
so.addParam("wmode", "transparent");
so.write(this.id + "-swfPlayer-div");
so.addParam("allowScriptAccess", "always");
so.addVariable("url", escape(previewCtx.url));
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.