jaikar Posted June 10, 2007 Share Posted June 10, 2007 Hi, if the server limits the size of the upload file to 2MB, is there a way to increace the limit from the code? Thanks ~J Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/ Share on other sites More sharing options...
Hypnos Posted June 10, 2007 Share Posted June 10, 2007 Put something like: <input type="hidden" name="MAX_FILE_SIZE" value="3000000" /> in your html form. Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/#findComment-271897 Share on other sites More sharing options...
jaikar Posted June 10, 2007 Author Share Posted June 10, 2007 i dont think this will affect the server limits, because to my knowledge the Max file size on the form should b used when the server has limts like 100 and if you manualy want to restrict the file size to 10 or 20 you can use that ..... i am looking for the function in php like, set_interval someting like this which will replace the value in the php.ini file. bcause the file upload is restricted in the php.ini file so, is there a function to change this limit and increate the upload size ? Thanks ~J Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/#findComment-271903 Share on other sites More sharing options...
Hypnos Posted June 10, 2007 Share Posted June 10, 2007 Right. It really depends on your php.ini settings, and wether or not you can override them. And that's not just specific to the options related to these settings. You can use set_ini, .htaccess, or sometimes your host will let you have mini php.ini files. It really depends on your host, and what they allow. They might not allow any overrides. Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/#findComment-271914 Share on other sites More sharing options...
jaikar Posted June 10, 2007 Author Share Posted June 10, 2007 well .. then i will check this out with the host Thanks ! Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/#findComment-271942 Share on other sites More sharing options...
jaikar Posted June 10, 2007 Author Share Posted June 10, 2007 ok .. this is the code to be placed on the htaccess php_value post_max_size 8M php_value upload_max_filesize 8M Link to comment https://forums.phpfreaks.com/topic/54996-file-uploading/#findComment-271954 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.