/p5-text-docx

Process a Docx as template and save a rendered docx file

Primary LanguagePerl

Text::Docx - Office Docx as Template

This module is a tool that provide a simple way to transform a docx office file in a template using the tradictional [% tags %] for replace stash variables.

Synopsis

use Text::Docx;

# getting a new instance
my $template = Text::Docx->new( '/path/to/template.docx' );

# basic stash
my $stash = {
    foo => 'foo value', bar => 'bar value',
};

# process template and save docx file
$template->process( $stash )
    ->save_to( '/path/to/new/file.docx' );

and in docx file we have something like:

You is the [% foo %] of my [% bar %]!!!

Author

Daniel Vinciguerra <daniel.vinciguerra@bivee.com.br>

2013 (c) Bivee

http://bivee.com.br

Copyrights and Licenses

This software is copyright (c) 2013 by Bivee.

This is a free software; you can redistribute it and/or modify it under the same terms of Perl 5 programming languagem system itself.