{"id":1876,"date":"2010-11-15T10:25:00","date_gmt":"2010-11-15T10:25:00","guid":{"rendered":"http:\/\/mts-help.nick.php.dev\/after_sale_support\/Working_with_Dynamic_Flash_Galleries\/article7.html"},"modified":"2011-03-23T03:41:28","modified_gmt":"2011-03-23T07:41:28","slug":"how-increase-max-file-size","status":"publish","type":"post","link":"https:\/\/www.templatemonster.com\/help\/how-increase-max-file-size.html","title":{"rendered":"How to increase max file size"},"content":{"rendered":"If you want to use the images more than 2Mb, then please, do the following: <br \/> <br \/>You can do this by yourself if you&#8217;re working on the local machine or if you have an access to <span style=\"FONT-WEIGHT: bold\">php.ini<\/span> file on your server (you may also use <span style=\"FONT-WEIGHT: bold\">.htaccess<\/span> file with the same instructions in case your hosting allows to change this). <br \/>So, please, open <span style=\"FONT-WEIGHT: bold\">php.ini<\/span> file and find the lines: <br \/> <br \/> <div class=\"example_code\">&nbsp; <br \/>max_execution_time = 30; <br \/>max_input_time = 60; <br \/>&nbsp;<\/div> <br \/>change them to <br \/> <br \/> <div class=\"example_code\">&nbsp; <br \/>max_execution_time = 60; <br \/>max_input_time = 90; <br \/>&nbsp;<\/div> <br \/>and also change the line <br \/> <br \/> <div class=\"example_code\">&nbsp; <br \/>post_max_size = 2M; <br \/>&nbsp;<\/div> <br \/>to <br \/> <br \/> <div class=\"example_code\">&nbsp; <br \/>post_max_size = 4M; <br \/>&nbsp;<\/div> <br \/>in case you would like to upload the files up to 4 Mb. <br \/> <br \/> <div class=\"example_code\">&nbsp; <br \/> <span style=\"FONT-WEIGHT: bold\">max_execution_time<\/span> &#8211; integer <br \/> <br \/>This sets the maximum time in seconds a script is allowed to run before it is terminated by the parser. This helps prevent poorly written scripts from tying up the server. The default setting is 30. The maximum execution time is not affected by system calls, stream operations etc. Please see the set_time_limit() function for more details. <br \/>You can not change this setting with ini_set() when running in safe mode. The only workaround is to turn off safe mode or by changing the time limit in the php.ini. <br \/>Your web server can have other timeouts. E.g. Apache has Timeout directive, IIS has CGI timeout function, both default to 300 seconds. See the web server documentation for meaning of it. <br \/>&nbsp;<\/div> <br \/> <div class=\"example_code\">&nbsp; <br \/> <span style=\"FONT-WEIGHT: bold\">max_input_time<\/span> &#8211; integer <br \/> <br \/>This sets the maximum time in seconds a script is allowed to parse input data, like POST, GET and file uploads. <br \/>&nbsp;<\/div> <br \/> <div class=\"example_code\">&nbsp;&nbsp; <br \/> <span style=\"FONT-WEIGHT: bold\">post_max_size<\/span> &#8211; integer <br \/> <br \/>Sets max size of post data allowed. This setting also affects file upload. To upload large files, this value must be larger than upload_max_filesize. If memory limit is enabled by your configure script, memory_limit also affects file uploading. Generally speaking, memory_limit should be larger than post_max_size. <br \/>When an integer is used, the value is measured in bytes. You may also use shorthand notation as described in this FAQ. <br \/>If the size of post data is greater than post_max_size, the $_POST and $_FILES superglobals are empty. This can be tracked in various ways, e.g. by passing the $_GET variable to the script processing the data, i.e. &lt;form action=&#8221;edit.php?processed=1&#8243;&gt;, and then checking if $_GET[&#8216;processed&#8217;] is set. <br \/>&nbsp;<\/div> <br \/>Please, refer to <a class=\"link3\" href=\"http:\/\/ie.php.net\/info\/\">http:\/\/ie.php.net\/info\/<\/a> for more info.","protected":false},"excerpt":{"rendered":"<p>If you want to use the images more than 2Mb, then please, do the following: You can do this by yourself if you&#8217;re working on the local machine or if you have an access to php.ini file on your server (you may also use .htaccess file with the same instructions in case your hosting allows [&hellip;]<\/p>\n","protected":false},"author":13,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[282,752],"tags":[502,501],"_links":{"self":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/1876"}],"collection":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/comments?post=1876"}],"version-history":[{"count":0,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/1876\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/media?parent=1876"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/categories?post=1876"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/tags?post=1876"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}