ARI Docs Viewer system plugin helps to embed files in the following formats into any Joomla! content:
- doc / docx - Microsoft Word Document
- xls / xlsx - Microsoft Excel Spreadsheet
- ppt / pptx - Microsoft PowerPoint
- pps - PowerPoint Slideshow
- odt - OpenDocument Text
- ods - OpenDocument Spreadsheet
- odp - OpenDocument Presentation
- sxw - OpenOffice.org Writer Document
- sxc - OpenOffice.org Calc Spreadsheet
- sxi - OpenOffice.org Impress Presentation
- wpd - Corel Word Perfect Document
- pdf - Adobe Portable Document Format
- rtf - Rich Text Format
- html - Hyper Text Markup Language
- txt - Plain Text Document
- csv - Comma Separated Values
- tsv - Tab Separated Values
- pages - Apple Pages
- ai - Adobe Illustrator
- psd - Adobe Photoshop
- dxf - Autodesk AutoCad
- svg - Scalable Vector Graphics
- eps / ps - PostScript
- ttf - TrueType
- xps - XML Paper Specification
One note, if Google Docs Viewer or "Office Docs Viewer" service is used to insert a document, it requires internet connection. It means that this feature might not work on local network sites if they does not have access to the Internet.
The add-on can also embed external pages and Joomla! articles into Joomla! content. "ARI Docs Viewer" package contains "Button - ARI Docs Viewer" plugin which adds "Embed doc" button to Joomla! editors and help to generate shortcodes for "System - ARI Docs Viewer" plugin.
Examples
How to embed document with the supported format into content?
Use the following code:
{aridoc engine="google" width="600" height="300"}PATH_TO_DOCUMENT{/aridoc}
If you want to embed remote PDF file which is located by url http://www.domain.com/docs/doc1.pdf, use the next code:
{aridoc engine="google" width="600" height="300"}http://www.domain.com/docs/doc1.pdf{/aridoc}
If neccesary to load my_doc.doc Microsoft Word document which is stored on your site in [joomla_directory]/documents/ folder, use the following code:
{aridoc engine="google" width="550" height="450"}documents/my_doc.doc{/aridoc}
or
{aridoc engine="office" width="550" height="450"}documents/my_doc.doc{/aridoc}
Currently the extension supports three services for rendering documents: "Google Docs Viewer", "Office Docs Viewer" (it supports documents which are created in application from "MS Office" package) and "PDF JS" (only for PDF files). Use engine
parameter of {aridoc}
tag that choose which one do you want to use. For "Google Docs Viewer" use engine="google"
, engine="office"
for "Office Docs Viewer" and engine="pdfjs"
for "PDF JS".
How to embed external page?
Type the next code:
{aridoc engine="iframe" width="500" height="400"}LINK_TO_PAGE{/aridoc}
For example if you want to insert "ARI Soft" home page into an article, add the following code to necessary article:
{aridoc engine="iframe" width="100%" height="400"}http://www.ari-soft.com{/aridoc}
How to insert specific article into content?
Type the following code:
{aridoc engine="article" width="500" height="400" id="ARTICLE_ID"}{/aridoc}
If needed to embed article with ID equals to "45", use the next code:
{aridoc engine="article" width="500" height="400" id="45"}{/aridoc}
Parameters
{aridoc}
tag supports the following parameters:
- engine - indicates what engine will be used for showing document. Values: iframe, article, google, pdfjs;
- width - width of window where document is loaded. Values: number or number in percent;
- height - height of window where document is loaded. Values: number or number in percent;
- class - CSS class of container element. Can be used that add custom styles to container and document window. Values: class(es) name;
- loadingPane - indicated show or not loading icon and message while document is loading. Values: 1 or 0;
- showDownloadLink - show or not download link for embeding document. This parameter makes sense for Google viewer only. Values: 1 or 0,
Note: it is not necessary to specify all parameters in {aridoc}
tag, omitted parameters will be loaded from plugin settings.