wiki:DocRenderPlugin

Version 6 (modified by bsavelev, 19 months ago) (diff)

--

DocRenderPlugin -- preview for DOC/XLS files

Description

Mimeview plugin to render in preview mode doc/xls attachments.

This plugin uses headless OpenOffice/Libreoffice to generate html.

Bugs/Feature Requests

Existing bugs and feature requests for DocRenderPlugin are here.

If you have any issues, create a new ticket.

Download

Download the zipped source from here.

Source

You can check out DocRenderPlugin from here using Subversion, or browse the source with Trac.

Example

Sample init-script (tested on Debian)

#!/bin/bash
# openoffice.org  headless server script
#
### BEGIN INIT INFO
# Provides:          openoffice
# Required-Start:    $all
# Required-Stop:     $all
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: openoffice headless
# Description:       openoffice headless
### END INIT INFO
# 
# Author: Vic Vijayakumar
# Modified by Federico Ch. Tomasczik
#
SOFFICE_PATH="/usr/lib/libreoffice/program/soffice.bin"
PIDFILE=/var/run/openoffice-server.pid

case "$1" in
    start)
    if [ -f $PIDFILE ]; then
      echo "OpenOffice headless server has already started."
      sleep 5
      exit
    fi
      echo "Starting OpenOffice headless server"
      $SOFFICE_PATH --headless --nologo --nofirststartwizard --nodefault --accept="socket,host=localhost,port=8100;urp;StarOffice.ComponentContext" & > /dev/null 2>&1
      echo $! > $PIDFILE
    ;;
    stop)
    if [ -f $PIDFILE ]; then
      echo "Stopping OpenOffice headless server."
      kill -9 `head $PIDFILE`
      rm -f $PIDFILE
      exit
    fi
      echo "Openoffice headless server is not running."
      exit
    ;;
    *)
    echo "Usage: $0 {start|stop}"
    exit 1
esac
exit 0

Execute init-script, install plugin and edit attachment section in trac.ini

[attachment]
ooo_socket = socket,host=localhost,port=8100

Recent Changes

[11631] by bsavelev on 2012-06-07 07:14:56
fix typo
[11629] by bsavelev on 2012-06-06 12:48:07
use uno for converting
[10897] by bsavelev on 2011-11-10 09:00:36
add pdf support

Author/Contributors

Author: bsavelev
Maintainer: bsavelev
Contributors:

Attachments (3)

Download all attachments as: .zip