On Mar 11, 12:59 pm, "marco.rizze...@gmail.com"
wrote:
> My question is:
> If in a model I have many image fields and many upload field how can I
> set the model to permit the use of AD7six Upload Behaviour with all
> these fields?
> Many Thanks
Hi Marco,
The o
My question is:
If in a model I have many image fields and many upload field how can I
set the model to permit the use of AD7six Upload Behaviour with all
these fields?
Many Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the
I think Is better to use the original path:
function afterSave() {
if (!empty($this->data[$this->name]['logo'])) {
$path= $output = str_replace("//", "/",
$this->data[$this->name]['original']);
@unlink($path);
Now everything is working like i expected.
To keep the file in {IMAGE}... and delete the file in {APP}... im
using the afterSave callback in my model:
function afterSave() {
if (!empty($this->data[$this->name]['logo'])) {
$baseDir= ROOT .
Im sharing the replace of double slashes and the path to convert, maybe
exist
a better way to achieve that.
function __imConvert(&$model, $input, $params = array(), $output =
null, $return = false) {
if (isset($params['return'])) {
$return = $params['return'];
Hi AD7six,
I was wondering how to auto-delete int add action the file uploaded to
{APP} after the file is converted in {IMAGES}?
Just only to keep the converted file and not the original uploaded
file.
Now i can save my image in a single field. Based in modifications to
allow
using a single fie
If I upload a file named:
Bloqueo con espacios .jpg
It is uploaded to uploads folder with filename bloqueo_con_espacios.jpg ,
but is not converted or resized in images path.
If I upload a file named:
Bloqueoconespacios.jpg
It is uploaded to uploads folder with filename bloqueoconespacios.jp
After almost 7 days of debuggin is done!
The problem was the fullpath of the convert command, i just
modified by hand the file image_upload.php, in the line 508 i
added the path to convert:
$command = "/usr/local/bin/convert $input $params $output";
My model is:
array(
Im using cakephp 1.2 and the behaviors:
http://trac.assembla.com/cake-base/browser/branches/sample_app/app/models/behaviors/upload.php
http://trac.assembla.com/cake-base/browser/branches/sample_app/app/models/behaviors/image_upload.php
And im trying to upload and save the image without using the
Why is so hard to share an example?
I have 7 days trying to upload, resize and save an image in
a single field named logo, I tried everything. This list is to
help people who knows how to ask for help, and i think
i asked nice for help, posting my code, trying to read the
api, searching in goolge
ok im still trying and i think im close:
Im my add action i have:
...
$this->Test->create();
$this->data['Test']['foreign_id'] = '';
$this->data['Test']['dir'] = 'listings';
$this->data['Test']['class']= '/listings';
$this->data['Test']['filename'] = $
> You can do this:
> $data = array($model->alias => array('x' => $y 'filename' =>
> array(..)));
> $this->MyModel->save($data);
>
> var $actsAs = array(
> 'ImageUpload' => array(
> 'fileFormat'=> '{$x}/{$filename}',
> )
> );
Maybe an example w
> You can do this:
> $data = array($model->alias => array('x' => $y 'filename' =>
> array(..)));
> $this->MyModel->save($data);
>
> var $actsAs = array(
> 'ImageUpload' => array(
> 'fileFormat'=> '{$x}/{$filename}',
> )
> );
Maybe an example w
On Sep 1, 7:31 am, Josoroma <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Somebody knows how to use and configure at model level the upload
> behavior of AD7Six, but without using the attachments
> table?http://groups.google.com/group/cake-php/browse_thread/thread/8ac41ad9...
>
> Any help is welcome.
>
Hi,
Somebody knows how to use and configure at model level the upload
behavior of AD7Six, but without using the attachments table?
http://groups.google.com/group/cake-php/browse_thread/thread/8ac41ad9dfd4bb7d/a1b2160874e5da48
Any help is welcome.
Thanks in advance.
--~--~-~--~~--
Now, in my Listing Model im using:
var $actsAs = array(
'ImageUpload' => array(
'fileField' => 'logo',
'allowedMime'=> array('image/jpeg', 'image/gif',
'image/png', 'image/bmp'),
'allowedExt'=> array('jpeg', 'jpg
Hi AD7Six,
I was seeing your behaviors, they looks very cool and useful. I was
wondering how to use the upload and image_upload behaviors without
using the attachments table.
...can just be a file field in your products table, or a dedicated
'attachments' table...
My field is logo, im using the
17 matches
Mail list logo