#!/bin/sh

# This file is part of the KDE project
# Copyright (C) 2002,2003 Paul Chitescu <paulc-devel@null.ro>
# License: Open Source, Use On Your Own Risk
#
# Konqueror/Embedded MS PowerPoint to HTML data filter
#
# Requires: sh, sed, ppthtml (xlhtml)
#
# Usage: in your konq-embedrc file,
#
# [MIME Handlers]
# application/vnd.ms-powerpoint,.ppt=|text/html|/path/to/this/file

# you shouldn't need to change anything below
case "$FILTER_URL" in
file:/*)
    ppthtml `echo "$FILTER_URL" | sed 's,^file:,,'`
    ;;
*)
    tmpf=/tmp/.konqe-dl-$$.ppt
    cat >$tmpf
    ppthtml $tmpf
    rm $tmpf
    ;;
esac

