How to import a file?

Author Message

Massimiliano Bariola

Wednesday 10 May 2006 8:48:38 am

Hi,

has anyone tried to import a binary file?

I am trying to create objects which have a "file" attribute, which will hold some pdfs. I am unable to understand how to use the functions in ezbinaryfile.php and ezbinaryfiletype.php to obtain this.

Xavier Dutoit

Wednesday 10 May 2006 9:22:35 am

Have a look at the contribs (the multiple file upload for instance). in import/export. This might give you an idea.

Keep us informed.

X+

http://www.sydesy.com

Massimiliano Bariola

Thursday 11 May 2006 9:47:30 am

Hi Xavier,

I found some code on the forum, but didn't work out-of-the-box - after a few hours I was able to tweak it to my needs.

thanks,

Massimiliano

Daniel Scheiner

Monday 14 August 2006 4:54:54 am

Hi Massimiliano!

Could you share that code?
Thanks!

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 06:19:23
Script start
Timing: Jan 31 2025 06:19:23
Module start 'layout'
Timing: Jan 31 2025 06:19:23
Module start 'content'
Timing: Jan 31 2025 06:19:23
Module end 'content'
Timing: Jan 31 2025 06:19:23
Script end

Main resources:

Total runtime0.0106 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.0046 588.0313151.1953
Module start 'layout' 0.00460.0018 739.226636.6172
Module start 'content' 0.00640.0029 775.843890.1250
Module end 'content' 0.00940.0012 865.968833.9922
Script end 0.0106  899.9609 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002019.1060140.0001
Check MTime0.00109.1384140.0001
Mysql Total
Database connection0.00065.990910.0006
Mysqli_queries0.001716.348230.0006
Looping result0.00000.076610.0000
Template Total0.00098.810.0009
Template load0.00076.925910.0007
Template processing0.00021.843010.0002
Override
Cache load0.00054.886910.0005
General
dbfile0.00022.041380.0000
String conversion0.00000.047340.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