[URGENT] Automatic PDF exportation...

Author Message

Francis Poézévara

Monday 13 August 2007 12:25:30 am

Hello everybody,

Here is my problematic : I need to store all the articles which are N months old, before deleting them in my database. These deletions are made by a php script, executed thanks to CRON... The best solution for the storage would be (in my opinion) to store each article in a PDF before deleting them.

But is it possible to generate them automatically in a php script ?

Thank you !

Francis Poézévara

Monday 13 August 2007 2:01:02 am

Well, I found a way to do that, with FPDF (found with google), by selecting the data directly from the database... Less sexy, but... :D

Heath

Monday 13 August 2007 2:04:21 am

Thats neat, why not share your solution with the community as a contribution on ez.no?

Cheers,
Heath

Brookins Consulting | http://brookinsconsulting.com/
Certified | http://auth.ez.no/certification/verify/380350
Solutions | http://projects.ez.no/users/community/brookins_consulting
eZpedia community documentation project | http://ezpedia.org

Francis Poézévara

Monday 13 August 2007 3:05:09 am

Hmm it really depends on the class of the site, so I can't really share this... Just see FPDF, it's really well explained :)

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 31 2025 04:27:14
Script start
Timing: Jan 31 2025 04:27:14
Module start 'layout'
Timing: Jan 31 2025 04:27:14
Module start 'content'
Timing: Jan 31 2025 04:27:14
Module end 'content'
Timing: Jan 31 2025 04:27:14
Script end

Main resources:

Total runtime0.0138 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0055 588.1328151.2109
Module start 'layout' 0.00550.0025 739.343836.6484
Module start 'content' 0.00800.0044 775.992290.1250
Module end 'content' 0.01240.0014 866.117233.9922
Script end 0.0138  900.1094 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002618.7263140.0002
Check MTime0.00118.0179140.0001
Mysql Total
Database connection0.00074.972410.0007
Mysqli_queries0.002417.225130.0008
Looping result0.00000.087910.0000
Template Total0.00117.910.0011
Template load0.00086.001410.0008
Template processing0.00031.844210.0003
Override
Cache load0.00064.114110.0006
General
dbfile0.00064.550280.0001
String conversion0.00000.034540.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs