Archive for the ‘PhpRtf’ Category

PHPRtfLite 1.0.1 has been released

Saturday, May 1st, 2010

I’m happy to announce the release of PHPRtfLite 1.0.1. There are not many changes made, but nevertheless it is worth to update. The changes are as follows:

  • Vertical alignment for tables caused broken layouts for OpenOffice and TextMaker,
  • and some small bugs

PHPRtfLite was tested with Microsoft® Office™ Professional 2003, OpenOffice 3.2 Write, and TextMaker Viewer 2010.

PHPRtfLite 1.0 has been released

Wednesday, March 31st, 2010

I’m happy to announce the 1.0 release of PHPRtfLite. The changes are as follows:

– Autoloader now validates class names for better security

– Replaced class PHPRtfLite_Note to PHPRtfLite_Footnote and PHPRtfLite_Endnote, because it’s more clear and a better OO-Design

– Bugs fixed: #2971336, #2969964

PHPRtfLite 1.0 RC1 has been released

Monday, March 15th, 2010

Download at:
https://sourceforge.net/projects/phprtf/files/phprtflite/phprtflite.1.0.0/phprtflite.1.0.0.zip/download

PHPRtfLite 1.0 is a full rewrite of the almost two years old version 0.3 and does now take advantages of PHP 5 object orientation.

What has changed:

– PHPRtfLite has a built-in autoloader, you may use, but you do not have to

– all classes are having the prefix PHPRtfLite to avoid name conflicts

– exception handling has been added

– setting borders has been changed

– constants has moved into the classes

– color hex numbers can be 3 or 6 digits (#f03 or #ff0033)

– showing a missing image, if the image file does not exists

– NEW FEATURE: footnote and endnote support

– and some bugs fixes

Some methods are renamed but, to keep a bit backward compatibility the old methods are still there, but will be removed in the future, may be in version 1.1 or later if users will need more time to adapt their code. (You will have to tell us.)

Sample files are also included, of course.

Future plans for PHPRtfLite

For getting the version 1.0 stable we will need your help. So please let us know about bugs, missing functionalities or circuitous behavior.

For the next version 1.1 we like to hear from you which functionalities you would desire most.

Here a list of possible features, that could be implemented for next version:

– Comments

– Table of contents

– Nested tables

– bullet lists

– your suggestion?

SVN repository folders changed

To checkout the version 1.0:

svn co
https://phprtf.svn.sourceforge.net/svnroot/phprtf/branches/v1.0

All bug fixes will be added to this branch (and of course to the trunk, too).

Older versions are available under tags.

PhpRtf on SourceForge

Thursday, May 1st, 2008

I created PhpRtf project on sourceforge. I moved sources of library to SVN repository. You can check out using command:

svn co https://phprtf.svn.sourceforge.net/svnroot/phprtf phprtf

Here you will find most up-to-date copy of library. Also, you can join development.

Support of merging cells in PhpRtf Lite

Monday, January 28th, 2008

PhpRtf Lite 0.3.0 released. The main feature added is support of merging cells in table. This feature is implemented in Table->mergeCells() method. Library can be downloaded from Download page.

Usage of cells merging can be found in Sample scripts.

PhpRtf tutorials in Italian

Monday, January 21st, 2008

Two PhpRtf tutorials in Italian are published on www.codicefacile.it/.

One is about creating simple .rtf document. Second is about creating tables in .rtf documents using PhpRtf.

PhpRtf Lite 0.2.1 released

Saturday, October 27th, 2007

• Added method Rtf::setLandscape() for setting landscape orientation of rtf document.

PhpRtf Lite 0.2.0 released

Sunday, August 12th, 2007

Some very strong bugs fixed.

Note: It’s possible, that after updating, your code which is using library will throw errors, and should be refactored.

• Documents with tables generated using PhpRtf Lite crashed in Microsoft Word 2000. Fix in Table::getContent method.

• Removed all call-times pass-by-reference from the library. Because with allow_call_time_pass_reference = false setting in php.ini, warnings were frown.

Also is changed Container::writeText() method declaration. Instead of variables are used instances:
Old declaration:
function writeText($text, $font, $parFormat = false, $replaceTags = true);
New declaration:
function writeText($text, &$font, &$parFormat, $replaceTags = true)

PHP 4 doesn’t let writing &$parFormat = 0 in declaration. So after updating library, your code, which is using library, should be refactored.

Instead of writing:
$sect->writeText(‘RTF PHP’, new Font());
or
$section->writeText(‘RTF PHP’, new Font(), false);

You have to write:
$null = null;
$sect->writeText(‘RTF PHP’, new Font(), $null);

As third argument is used null reference. Look at the samples for more information.

• Also removed possibility to use <page> and <section> tags in Container:writeText() method.
Instead of using <section>, you should create new section. Instead of using <page> tag, you should use Section::insertPageBreak() method (that’s done, because, page breaking shouldn’t be used in headers, footers and cells).

PhpRtf Lite 0.1.1 released

Friday, July 6th, 2007

Just few bug fixes:

• In Rtf->sendRtf method added line: header(’Content-type: application/msword’).
• Fixed bug in ParFormat constructor. Didn’t work well with justify alignment.
• In Cell->setDefaultAlignment added possibility to set justify alignment.

PhpRtf Lite First Beta released

Tuesday, May 15th, 2007

We are proud to announce that PhpRtf Lite First Beta is currently released and is available to download from our site.