Jump to content

Archived

This topic is now archived and is closed to further replies.

eranwein

uploading files in hebrew

Recommended Posts

i know that it's a problem most of you didnt encounter with, but still...

i'm trying to upload files.
this is the code i'm using:

if (move_uploaded_file($_FILES['uploadedFile']['tmp_name'],$file_path)) print "file insert"
else print "file not insert";

when i'm trying to upload files containing hebrew words, it doesnt do anything.
it doesnt even print "file not insert".

is there any configuration i have to do ?

Share this post


Link to post
Share on other sites
uploading files is done in binary, so the language within the file wont make a difference to anything.
my guess is that you've got an error, but have error_reporting too low or display_errors set to off in your php.ini file, so you arent seeing the problem.

but you have a missing ; at the end of your line:

[code]
if (move_uploaded_file($_FILES['uploadedFile']['tmp_name'],$file_path))
   print "file insert";  <--- here
else
   print "file not insert";
[/code]

Share this post


Link to post
Share on other sites
the missing ; is not relavent because it's not copy+paste from the code.
how do io set my error reporting to display my problam?

Share this post


Link to post
Share on other sites
[!--quoteo(post=356914:date=Mar 21 2006, 11:56 AM:name=eranwein)--][div class=\'quotetop\']QUOTE(eranwein @ Mar 21 2006, 11:56 AM) [snapback]356914[/snapback][/div][div class=\'quotemain\'][!--quotec--]
the missing ; is not relavent because it's not copy+paste from the code.
how do io set my error reporting to display my problam?
[/quote]

a few ways. change your php.ini file directly, use a .htaccess file, or at the top of your scripts put:

[code]
error_reporting(2039);
ini_set("display_errors","on");
ini_set("display_startup_errors","on");
[/code]

for some reason when i do it this way, if the script has a major error it doesnt seem to tell me. so i'd recommend making a text file in your root called .htaccess, and putting the lines:

[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]
php_flag display_errors on
php_value error_reporting 2039
[/quote]

in it. this will show you all the important stuff and should let you know exactly what your problem is

cheers

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.