[PHP] Opera broswer file upload / MY CODE

2002-03-14 Thread Vlad Kulchitski

This is the code I am using for uploading:

if(($userfile)  ($userfile != none))
{

  $type=basename($userfile_type);

  
  switch ($type) 
  {
   case jpeg:

   case pjpeg: $filename=talkroom_gallery_photographs/$username.jpg;
 copy($userfile, $filename);
 echo file copied OK!;
 echo img src=$filename;
 break;
   case gif:   $filename=talkroom_gallery_photographs/$username.gif;
 copy($userfile, $filename);
 echo file copied OK!;
 echo img src=$filename;
 break;
   case bmp:   $filename=talkroom_gallery_photographs/$username.bmp;
 copy($userfile, $filename);
 echo file copied OK!;
 echo img src=$filename;
 break;
   default:  echo invalid picture format;
}

Vlad

-Original Message-
From: Jason Wong [mailto:[EMAIL PROTECTED]] 
Sent: 14 ÂÅÒÅÚÎÑ 2002 Ò. 10:58
To: [EMAIL PROTECTED]
Subject: Re: [PHP] Opera broswer  file upload

On Thursday 14 March 2002 23:57, Vlad Kulchitski wrote:
 Also another question, my fileupload works everywhere (IE, Netscape) but
 Opera. Does Opera support it at all?

 My fileupload is very simple. It checks is the file is JPEG/GIF/BMP and
 then
 saves it, if not, gives an error message.

I use Opera 5.12 for uploads and have no problems.


What problems are you getting?

-- 
Jason Wong - Gremlins Associates - www.gremlins.com.hk

/*
The more crap you put up with, the more crap you are going to get.
*/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Opera broswer file upload / MY CODE

2002-03-14 Thread Jason Wong

On Friday 15 March 2002 00:10, Vlad Kulchitski wrote:
 This is the code I am using for uploading:

 if(($userfile)  ($userfile != none))
 {

   $type=basename($userfile_type);

[snip]


Hmm, Andrey says the bug has been fixed and committed to the CVS. But looking 
at the bug reports there have been quite a number of fixes for Opera, and 
uploads against various versions of PHP.

So your best bet is to search at http://bugs.php.net for your particular 
version of php and see what comes up.


-- 
Jason Wong - Gremlins Associates - www.gremlins.com.hk

/*
He who hates vices hates mankind.
*/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php