Miles J Uploader

2012-09-10 Thread CrotchFrog
I'm using Miles J Uploader plugin and Cake 2.2.2. I've configured the plugin in my model as $actsAs = Uploader.attachment. What I'm having problems with is that I have a custom function in the bootstrap to save the file with a unique filename and that works ok but its saves the record

Re: Miles J Uploader

2012-09-10 Thread Johannes N
, On Monday, September 10, 2012 2:01:16 PM UTC+2, CrotchFrog wrote: I'm using Miles J Uploader plugin and Cake 2.2.2. I've configured the plugin in my model as $actsAs = Uploader.attachment. What I'm having problems with is that I have a custom function in the bootstrap to save the file

Re: Miles J Uploader

2012-09-10 Thread Ed Propsner
', 5. 'overwrite' = false, 6. 'stopSave' = true, 7. 'allowEmpty'= false, 8. ); greetings, On Monday, September 10, 2012 2:01:16 PM UTC+2, CrotchFrog wrote: I'm using Miles J Uploader plugin and Cake 2.2.2. I've configured the plugin

Re: Problem with Miles J. Uploader plugin and image name

2012-05-05 Thread Xoubaman
3.5 El sábado, 5 de mayo de 2012 06:10:32 UTC+2, Miles J escribió: What version are you using? On Thursday, May 3, 2012 9:49:21 AM UTC-7, Xoubaman wrote: This is my behavior setup: public $actsAs = array( 'Uploader.Attachment' = array( 'image_upload' = array(

Re: Problem with Miles J. Uploader plugin and image name

2012-05-04 Thread Xoubaman
Mmmm... sad that after try lots of things I missed one so obvious. But, now that the naming problem is solved, the thumb generation is producing an unexpected result, wrapping the image with smaller width and height into a black square of the passed mesaures Here is a capture:

Re: Problem with Miles J. Uploader plugin and image name

2012-05-04 Thread Xoubaman
After further investigation, the black square only apperas when the first resize operation actually takes place. If the source image is smaller than the max hegith and width, the thumb is correctly generated. If I add a third transform, with the same params as the second changing the append

Re: Problem with Miles J. Uploader plugin and image name

2012-05-04 Thread Xoubaman
After further investigation, the black square only apperas when the first resize operation actually takes place. If the source image is smaller than the max hegith and width, the thumb is correctly generated. If I add a third transform, with the same params as the second changing the append

Re: Problem with Miles J. Uploader plugin and image name

2012-05-04 Thread Miles J
What version are you using? On Thursday, May 3, 2012 9:49:21 AM UTC-7, Xoubaman wrote: This is my behavior setup: public $actsAs = array( 'Uploader.Attachment' = array( 'image_upload' = array( 'name'= 'formatFileName', 'baseDir'

Problem with Miles J. Uploader plugin and image name

2012-05-03 Thread Xoubaman
This is my behavior setup: public $actsAs = array( 'Uploader.Attachment' = array( 'image_upload' = array( 'name'= 'formatFileName', 'baseDir'= IMAGES, 'uploadDir'= 'writers', 'dbColumn'=

Re: Problem with Miles J. Uploader plugin and image name

2012-05-03 Thread Miles J
Are you trying to overwrite the original image with the resized one? Try adding overwrite = true to the resize transformation. On Thursday, May 3, 2012 9:49:21 AM UTC-7, Xoubaman wrote: This is my behavior setup: public $actsAs = array( 'Uploader.Attachment' = array(

Re: @Miles J - Uploader

2012-03-11 Thread Miles J
Awesome :] Glad you got it working. On Saturday, March 10, 2012 11:31:37 PM UTC-8, CrotchFrog wrote: @Miles: I have it working as expected now. The problem was that I was inadvertently supplying delete() with an array. I was using named keys in the array and Cake's Core Model.php read()

Re: @Miles J - Uploader

2012-03-10 Thread CrotchFrog
@Miles: I have it working as expected now. The problem was that I was inadvertently supplying delete() with an array. I was using named keys in the array and Cake's Core Model.php read() if (is_array($this-id)) { $id = $this-id[0]; } was failing with an undefined index [0]. I sorted out the

Re: @Miles J - Uploader

2012-03-09 Thread Miles J
Can you throw some debug($path)'s in Uploader.delete() to see if its generating the correct absolute path. On Thursday, March 8, 2012 9:38:05 PM UTC-8, CrotchFrog wrote: Using Cake 2.1 Uploader 3.3 'Uploader.Attachment' = array( 'fileName' = array( 'name' = 'generateFilename', 'baseDir'

Re: @Miles J - Uploader

2012-03-09 Thread CrotchFrog
It's correctly generating the path and works fine when manually deleting with Uploader. On Friday, March 9, 2012 1:30:31 PM UTC-5, Miles J wrote: Can you throw some debug($path)'s in Uploader.delete() to see if its generating the correct absolute path. On Thursday, March 8, 2012 9:38:05

Re: @Miles J - Uploader

2012-03-09 Thread Miles J
Does the debug() statement appear when doing a model delete? On Friday, March 9, 2012 9:25:09 PM UTC-8, CrotchFrog wrote: It's correctly generating the path and works fine when manually deleting with Uploader. On Friday, March 9, 2012 1:30:31 PM UTC-5, Miles J wrote: Can you throw some

@Miles J - Uploader

2012-03-08 Thread Ed Propsner
@Miles, With the newest version of your uploader, when deleting a row from the db the corresponding file should be deleted locally. I have everything else working great except for file deletion. What am I overlooking? Regards, ED -- Our newest site for the community: CakePHP Video Tutorials

Re: @Miles J - Uploader

2012-03-08 Thread Miles J
File deletion during row deletion works fine in my test cases. What versions are you using? (I haven't touched file deletion in a long time) Whats your behavior settings look like? What type of association? Or is it direct? On Thursday, March 8, 2012 12:56:50 AM UTC-8, CrotchFrog wrote:

Re: @Miles J - Uploader

2012-03-08 Thread CrotchFrog
Using Cake 2.1 Uploader 3.3 'Uploader.Attachment' = array( 'fileName' = array( 'name' = 'generateFilename', 'baseDir' = '', 'uploadDir' = 'img/artist', 'dbColumn' = 'path', 'importFrom' = '', 'defaultPath' = '', 'maxNameLength' = 30, 'overwrite' = true,

Miles J - Uploader - HABTM

2011-10-03 Thread styks1987
https://github.com/milesj/cake-uploader/issues/24 I have opened an issue about this problem. Does anybody have an idea of why it may not work? -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and

Miles J - Uploader plugin - issues with habtm?

2011-05-25 Thread designv...@gmail.com
Hi there, Has anyone noticed any issues with the Miles J Uploader pluign (http:// milesj.me/code/cakephp/uploader) when used in forms that have HABTM elements? If I comment out the the habtm field the uploader works like a charm, as soon is its present though it fails to upload the files return

Re: Miles J Uploader help

2010-06-04 Thread bradmaxs
Hey Miles or Anyone??, I feel like I found the problem with the uploader not accepting the birthdate array and before scrapping this uploader and moving to something different or changing the datetime field (I want to try and stick to cake's automagic form elements) I am going for one last

Re: Miles J Uploader help

2010-06-02 Thread bradmaxs
Hey Miles, Did you ever test this? Just checking. I am going to try and maybe do a Set::extract?? Going to start tomorrow but thought I would check in. Brad On May 19, 11:37 am, Miles J mileswjohn...@gmail.com wrote: Its probably getting confused trying to load the data since both the file

Re: Miles J Uploader help

2010-05-19 Thread bradmaxs
Hey Miles, That worked for a straight upload action, thank you. The Model Attachment is still not working for me though, still getting the errors from the above post. After looking closer it seems that my birthdate field is doing something funny?? Warning (2): Invalid argument supplied for

Re: Miles J Uploader help

2010-05-19 Thread Miles J
Its probably getting confused trying to load the data since both the file input and date input are arrays. I dont think I have ever tested with a date/time input, ill try it out. On May 19, 11:23 am, bradmaxs b...@pezzano.com wrote: Hey Miles, That worked for a straight upload action, thank

Re: Miles J Uploader help

2010-05-18 Thread Miles J
Let me do a few local tests. In the mean time, take a look at the example controller in the plugin. On May 17, 9:52 pm, bradmaxs b...@pezzano.com wrote: Hey Miles, Thanks for the fast reply.  For some reason i am only seeing your last post.  Google groups is acting funny for me.  I saw in the

Re: Miles J Uploader help

2010-05-18 Thread bradmaxs
I tried to just add it as an action in my controller and can't get a photo uploaded at all?? permissions are set to 777 on both my files folder and img_usericon as well. Here is the user_preferences_controller.php var $components = array('Uploader.Uploader'); in my beforeFilter

Re: Miles J Uploader help

2010-05-18 Thread Sam Sherlock
Hi Brad It is not a compatiblity issue with 1.3 - not able to speify the issue right now but will try to compare your code with mine later today but you may solve it by then :) - S On 18 May 2010 18:41, bradmaxs b...@pezzano.com wrote: I tried to just add it as an action in my controller

Re: Miles J Uploader help

2010-05-18 Thread Miles J
If you are using the latest uploader version, I believe its: if ($data = $this-Uploader-upload('UserPreference.fileName')) { On May 18, 11:14 am, Sam Sherlock sam.sherl...@gmail.com wrote: Hi Brad It is not a compatiblity issue with 1.3 - not able to speify the issue right now but will try

Miles J Uploader help

2010-05-17 Thread bradmaxs
I am trying to implement miles j's uploader plugin and am having trouble making it work. I keep getting this error: Warning (2): Invalid argument supplied for foreach() [APP/plugins/uploader/controllers/components/uploader.php, line 1006] First and foremost I am using cakephp version 1.3 so I am

Re: Miles J Uploader help

2010-05-17 Thread Miles J
Im pretty sure you do not need this line: if ($data = $this-Uploader-upload('image')) { The Attachment behavior does the uploading automatically. Also if you want to validate the image (like dimension size), you will need to use the Attachment and FileValidation behavior at the same time. On

Re: Miles J Uploader help

2010-05-17 Thread Miles J
Also forgot to say, this line should be image instead of file, since thats what you called it with the form helper. 'Uploader.Attachment' = array( 'image' = array( On May 17, 7:57 pm, bradmaxs b...@pezzano.com wrote: I am trying to implement miles j's uploader plugin and am having

Re: Miles J Uploader help

2010-05-17 Thread bradmaxs
Hey Miles, Thanks for the fast reply. For some reason i am only seeing your last post. Google groups is acting funny for me. I saw in the email summary that you left 2 messages but only see the one here. I did see in the email summary that the first post you said I didn't need this in my

Miles J Uploader

2010-03-01 Thread Dave
I cant resize an image and just not sure where im going wrong since it seems pretty clear. I canupload animage but after that when I add the resize I get nothing. Ideas? My function: function admin_add() { if (!empty($this-data)) { if ($data =

Re: Miles J Uploader

2010-03-01 Thread Miles J
Does $resized_path output an actual path? And does the image exist in the upload directory? On Mar 1, 3:54 pm, Dave make.cake.b...@gmail.com wrote: I cant resize an image and just not sure where im going wrong since it seems pretty clear. I canupload animage but after that when I add the resize