File uploading
Sir,
I cannot upload file of size 75mb in php.Is there is limit in php it cannot upload of file size of more than 50 mb.
Thanks in advance,
ArunKumar
Create a <?php phpinfo() ?> page.
Any upload/post limits should be stated on there.
Sir,
Where should i create phpinfo file
ArunKumar
Anywhere where you can access it via a url.
For example, if your url is http://foobar.com then create a phpinfo.php file with the following in it:
PHP Code:
<?php phpinfo () ?>
Put phpinfo.php into your sites document root (where the index.php file is) and goto http://foobar.com/phpinfo.php
Be sure to remove phpinfo.php once you're done to prevent other people from viewing it.
sir,
I cant get you,I am soory for it.The below is my code how to do i sir.
/*********************************************************/
<? include "pathfile.php";
echo " <form enctype=\"multipart/form-data\" action=\"".$pathconfig."backupload.php\" method=\"POST\">\n";
echo " Send this file: <input name=\"tst\" type=\"file\" /> \n";
echo " <input type=\"submit\" value=\"Send file\" /> \n";
echo " </form> \n";
?>
/***********My link goes here****************************/
if (isset($_fileS['tst']) && is_array($_fileS['tst']) && isset($_fileS['tst']['tmp_name']) && is_uploaded_file($_fileS['tst']['tmp_name'])) {
copy($_fileS['tst']['tmp_name'], 'upload/'.$_fileS['tst']['name']);
unlink($_fileS['tst']['tmp_name']);
echo 'uploaded file: '.$_fileS['tst']['name'].', '.$_fileS['tst']['size'].' bytes';
}
///////////////////////******************************//////////
The phpinfo.php file above is a completely new file you need to create ... forget about any existing files you may currently have.
Just create a brand new file called phpinfo.php (as above) and upload/ftp it to your host/server. Put it in the same place as your index.php file (or index.html) then goto http://yoursite.com/phpinfo.php
Sir,
I am trying to uploads a rar file.
I simply want to upload a file more that 60 mb.
I face the same problem when downloading also.
Thanks,
Arunkumar
Yes, but you need to find out why you are having this problem.
A <?php phpinfo() ?> file will show you all your PHP/Apache settings, some of those are related to uploading files, you need to check them to make sure there's no predefined file size limit.
If you do what i suggested above and view http://yoursite.com/phpinfo.php you'll see what i mean.
Sir
I doit as you said but there are more value displaying what to do it.
Thanks,
Arunkumar
Sir
I doit as you said but there are more value displaying what to do it.
Thanks,
Arunkumar
I presume you now see a page similar to this example one http://cirtexhosting.com/phpinfo.php ?
If so, what are the values of:
post_max_size
upload_max_filesize
?
sir,
Ya sir,I am having it .The values are 8.
ArunKumar
8? Hmm..that means you have a limit of 8M (and your form isn't specifying any limit).
That means you should only be able to upload 8M files so not even sure how you can upload a 50M one
You don't have to call be sir by the way ... that's my dad
hello mark,
How can i change,Is there is anyway to change.
And i feel very pleasure to get answer from you,And i like your last mail.
Can I get your mail id,
Mines is arun@bandvalley.com
Thanks,
Arun Kumar
Some hosts won't allow you to change the upload limit but you can try creating a .htaccess file.
So .. create a new file, called .htaccess and in there put:
php_value upload_max_filesize "100M"
php_value post_max_size "100M"
then upload the .htaccess file to your host, the same way you did it with the phpinfo.php file.
Is the file extension is .htaccess
ArunKumar
That's the entire file name, just .htaccess nothing else
I have created it bi=ut still it not working
i have just typed what you give is there neccesarry to put $ infront of php_ value.....
No, you don't need the $
Like i said, some hosts won't allow you to change it .. i'm presuming this isn't your server but a hosts?
Is that require put these under php tag <? ?>
Arunkumar
No, this is nothing PHP specific.
i saved it as
php_value upload_max_filesize "10000M"
php_value post_max_size "10000M"
and file name is .htaccess and then i store it in my server diredotry where all my php prgramms are there but still i cannot upload the file
should i save these in /etc/lib
Arun
sir,
I have changed still i cannot download it.
ArunKumar
The .htaccess goes where you originally had it (where you PHP files are .. index.php etc) not in /etc/lib
But it looks like your host doesn't allow you to upload files over 8M to prevent people uploading massive files and clogging up their server.
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks