Re: Download code for downloading a file

2009-07-24 Thread Rufus
I would imagine if you are getting an empty file you a referencing the file incorrectly. Try echo out your path and make sure its correct. make sure On Jul 24, 5:39 pm, Vijay Kumbhar wrote: > i have removed that array too. but it is not still giving the file to > download. > > > > On Fri, Jul 2

Re: Download code for downloading a file

2009-07-24 Thread Rufus
Here is my code: pdfDir is defined constant fyi function download($id = null) { if (!$id && empty($this->data)) { $this->Session->setFlash(__('Invalid Invoice', true)); $this->redirect(array('action'=>'index'));

Re: Real noob question

2009-06-17 Thread Rufus
Coffee and lunch = $this->set('total', $this->Inventory->find ('count')); On Jun 18, 12:48 pm, Rufus wrote: > I have a simple count: > >         function view($id = null) { >                 if (!$id) { >                         $this->Ses

Real noob question

2009-06-17 Thread Rufus
I have a simple count: function view($id = null) { if (!$id) { $this->Session->setFlash(__('Invalid Inventory.', true)); $this->redirect(array('action'=>'index')); } $this->set('inventory', $t

Re: What do you develop in (ide, text editor, etc.)?

2009-04-15 Thread Rufus
pspad On Mar 2, 7:35 am, Samuel DeVore wrote: > a tutu and go go boots > > On Sun, Mar 1, 2009 at 12:34 PM, Tomás Laureano Peralta Tormey > > wrote: > >  Currently using NetBeans 6.5. The hints from this bakery article [1] were > > really useful. > >  Hopefully, better support for CakePHP could

Re: Getting kicked out by auth when displaying blobs

2009-04-14 Thread Rufus
e, one point to note is that with caching, the binary data will > get served from the file system in most cases anyway. > > On Apr 15, 9:08 am, Rufus wrote: > > > The images are from 4-20k max and it seems pretty darn speedy. Also > > the web app is just a management portal

Re: Getting kicked out by auth when displaying blobs

2009-04-14 Thread Rufus
The images are from 4-20k max and it seems pretty darn speedy. Also the web app is just a management portal for an advertising widget, so it will only be used by 3 or 4 people at any one time. So I think nobody can argue that it is not ok to store it as a blob in this situation? On Apr 15, 2:04 

Re: Getting kicked out by auth when displaying blobs

2009-04-13 Thread Rufus
2nd request for the img. That's not out > of the ordinary, in itself, but this request goes through Dispatcher > and so Auth gets involved. It may have something to do with > Security.level (in core.php) being set to 'high'. > > On Mon, Apr 13, 2009 at 3:49 AM, Rufus wr

Re: Getting kicked out by auth when displaying blobs

2009-04-13 Thread Rufus
Also I am displaying the image like so: http://site.com/ images/display/'.$image['Image']['id'].'" title="'.$image['Image'] ['name'].'" alt="'.$image['Image']['name'].'" />'; ?> This is where the problem lies I think --~--~-~--~~---

Getting kicked out by auth when displaying blobs

2009-04-13 Thread Rufus
Ahoi, I have been getting kicked out of cake whenever I display a blob image in cake. Here is my function: function display($id) { if (!$id) { $this->Session->setFlash(__('Invalid Image.', true)); $this->redirect(array('action'=>'index')

Re: Display a blob in a view

2009-03-17 Thread Rufus
Yes Daffy you have the ticket. It seems you cant set a variable off the array like i tried to do: this is bad: $type = $file['ImageUpload']['type']; header('Content-type: ' . $type); this is good: $type = $file['ImageUpload']['type']; here is a follow-up post: http://groups.google.com/grou

Blob image display problem solved

2009-03-17 Thread Rufus
Hi, I was trying to get an image to display using the following: function display($id) { Configure::write('debug', 0); $file = $this->Image->findById($id); $data = $file['Image']['image']; $type = $file['Image']['type'] header("Content-type: ".$type); echo $data; } o

Display a blob in a view

2009-03-17 Thread Rufus
Hi, I have going through all the discussions looking for an easy way to show a blob in a view. I have got to what I think is the most simple way of doing it. Controller: function display($id) { Configure::write('debug', 0); $file = $this->Image->findById($id); $type = $file['Image

Capture webcam stream from client and upload it as a flash video to server

2008-01-15 Thread rufus
Hi. Is it possible to get this in CakePHP? I think to use Red5 (osflash.org/red5) as a flash server, CakePHP, AMFPHP. I'd like to build something like Youtube Quick Upload. Has anyone got anything similar using these tools? Regards rufus --~--~-~--~~~---~--~