Unsure on uploading files...

Author Message

Clemens T

Thursday 02 June 2005 2:11:16 am

Hello to all,
I'm currently developing my own module and like to use the upload functionality build into ezPublish.

On my quest for glory I've seen there is an ezPublish class for this:
<b>eZContentUpload</b>

And the module has some documentation, but I'm unsure on how to actually upload a file. The template should contain a form which contains:

- the local file to upload
- a location in the content-tree
- ...what else? Are the names predefined?

Which of the upload functions available in eZContentUpload should I be calling using the template/form?
- eZContentUpload::upload(...)
- eZContentUpload::handleUpload(...)

I'm sorry if the question is too general, I'm still trying to learn ezPublish and if any of these questions are answered, I'd be helped! (It would save me a lot of time going through contributions etc).
Thanks.

Clemens

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 07:30:15
Script start
Timing: Jan 31 2025 07:30:15
Module start 'layout'
Timing: Jan 31 2025 07:30:15
Module start 'content'
Timing: Jan 31 2025 07:30:15
Module end 'content'
Timing: Jan 31 2025 07:30:15
Script end

Main resources:

Total runtime0.0155 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.0050 588.1328151.2109
Module start 'layout' 0.00500.0024 739.343836.6484
Module start 'content' 0.00740.0067 775.992286.0313
Module end 'content' 0.01410.0014 862.023429.9922
Script end 0.0155  892.0156 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002415.1754140.0002
Check MTime0.00116.8837140.0001
Mysql Total
Database connection0.00084.915210.0008
Mysqli_queries0.002214.091430.0007
Looping result0.00000.084510.0000
Template Total0.00116.810.0011
Template load0.00085.127110.0008
Template processing0.00031.695210.0003
Override
Cache load0.00053.302910.0005
General
dbfile0.002717.415780.0003
String conversion0.00000.038440.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