Re: [PHP] Image upload form

2005-06-15 Thread Jack Jackson
Yes, Jason, Those did it! Thanks so much for the help! Jason Wong wrote: On Thursday 16 June 2005 00:38, Jack Jackson wrote: //try to get image size; this returns false if this is not an actual image file. $image_test = getimagesize($local_file); if ($image_test !== false) {

Re: [PHP] Image upload form

2005-06-15 Thread Jason Wong
On Thursday 16 June 2005 00:38, Jack Jackson wrote: > //try to get image size; this returns false if this is not an actual > image file. >$image_test = getimagesize($local_file); > if ($image_test !== false) { > $mime_type = $_FILES['userfile']['type']; $_FILES['userfile'][

Re: [PHP] Image upload form

2005-06-15 Thread Jack Jackson
Richard Davey wrote: Hello Jack, Wednesday, June 15, 2005, 5:38:11 PM, you wrote: JJ> newfile returns: 0fdae2e9e6aa43f067a9dd780a5a36a6.jpg JJ> image_file returns: JJ> images/jpg/test/0fdae2e9e6aa43f067a9dd780a5a36a6.jpg JJ> images/jpg/test is set to 777 but I still get (Could not move file

Re[2]: [PHP] Image upload form

2005-06-15 Thread Richard Davey
Hello Jack, Wednesday, June 15, 2005, 5:38:11 PM, you wrote: JJ> newfile returns: 0fdae2e9e6aa43f067a9dd780a5a36a6.jpg JJ> image_file returns: JJ> images/jpg/test/0fdae2e9e6aa43f067a9dd780a5a36a6.jpg JJ> images/jpg/test is set to 777 but I still get (Could not move file to JJ> destination). Wha

Re: [PHP] Image upload form

2005-06-15 Thread Jack Jackson
Okay, I started seeing some of my mistakes. I am still having a great deal of trouble: newfile returns: 0fdae2e9e6aa43f067a9dd780a5a36a6.jpg image_file returns: images/jpg/test/0fdae2e9e6aa43f067a9dd780a5a36a6.jpg images/jpg/test is set to 777 but I still get (Could not move file to destinati

[PHP] Image upload form

2005-06-15 Thread Jack Jackson
Hi, After a disastrous first attempt (which uploaded images but only by chance) it was suggested I rework the entire thing. This one seems to check the file against getimagesize and if that doesn't prove false, check the type and make the extension then rename the file. But the moving part is n