{"id":1548,"date":"2018-09-25T15:37:16","date_gmt":"2018-09-25T15:37:16","guid":{"rendered":"https:\/\/www.xsofthost.com\/help\/?p=1548"},"modified":"2021-03-14T15:00:18","modified_gmt":"2021-03-14T15:00:18","slug":"how-to-change-the-maximum-upload-file-size-for-php","status":"publish","type":"post","link":"https:\/\/www.xsofthost.com\/help\/how-to-change-the-maximum-upload-file-size-for-php\/","title":{"rendered":"How to change the maximum upload file size for PHP"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"1548\" class=\"elementor elementor-1548\">\n\t\t\t\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-76720a89 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"76720a89\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-6f12e7bc\" data-id=\"6f12e7bc\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-fd0b1c1 elementor-widget elementor-widget-text-editor\" data-id=\"fd0b1c1\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\tThere are several scenarios that you might need to increase or decrease your php maximum upload file using php script files , and for those cases you have two ways to reach the goal , either using cPanel WHM control panel or by editing the php.ini file directly.\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-cb46cea elementor-widget elementor-widget-heading\" data-id=\"cb46cea\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\"><a href=\"http:\/\/cpanel\">Change maximum upload file size for PHP In cPanel\/WHM<\/a><\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-45b4449 elementor-widget elementor-widget-text-editor\" data-id=\"45b4449\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<ul>\n<li>Login to your <a href=\"https:\/\/www.xsofthost.com\/help\/tag\/cpanel\/\">cPanel WHM<\/a> control panel<\/li>\n<li>Navigate to Home \u00bbSoftware \u00bbMultiPHP INI Editor<\/li>\n<li>Select Editor Mode and select the php version you are targeting then start edit the values :<\/li>\n<\/ul>\n<p>For example ; to Maximize allowed \u00a0size for uploaded files to 256 MB add these two values in php ini editor :<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-76c7211 elementor-widget elementor-widget-code-highlight\" data-id=\"76c7211\" data-element_type=\"widget\" data-widget_type=\"code-highlight.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"prismjs-solarizedlight copy-to-clipboard \">\n\t\t\t<pre data-line=\"\" class=\"highlight-height language-php line-numbers\">\n\t\t\t\t<code readonly=\"true\" class=\"language-php\">\n\t\t\t\t\t<xmp>uploadmax_filesize = 256M\npostmax_size = 256M\n<\/xmp>\n\t\t\t\t<\/code>\n\t\t\t<\/pre>\n\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-d4ef7fe elementor-widget elementor-widget-heading\" data-id=\"d4ef7fe\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Change maximum upload file size for PHP from php.ini<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-6e5db5f elementor-widget elementor-widget-text-editor\" data-id=\"6e5db5f\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<p>Or you can go directly to the php.ini file and start change the values for both <b>uploadmax_filesize<\/b> and postman_size .<\/p>\n<p>To locate the php.ini, you simply run the ssh command:<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-39e9e13 elementor-widget elementor-widget-code-highlight\" data-id=\"39e9e13\" data-element_type=\"widget\" data-widget_type=\"code-highlight.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"prismjs-okaidia copy-to-clipboard \">\n\t\t\t<pre data-line=\"\" class=\"highlight-height language-bash \">\n\t\t\t\t<code readonly=\"true\" class=\"language-bash\">\n\t\t\t\t\t<xmp>php -i | grep -i \u201cloaded configuration file\u201d<\/xmp>\n\t\t\t\t<\/code>\n\t\t\t<\/pre>\n\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>There are several scenarios that you might need to increase or decrease your php maximum upload file using php script files , and for those cases you have two ways to reach the goal , either using cPanel WHM control panel or by editing the php.ini file directly. Change maximum upload file size for PHP [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":44,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[194,6],"tags":[28,7],"_links":{"self":[{"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/posts\/1548"}],"collection":[{"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/comments?post=1548"}],"version-history":[{"count":14,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/posts\/1548\/revisions"}],"predecessor-version":[{"id":1800,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/posts\/1548\/revisions\/1800"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/media\/44"}],"wp:attachment":[{"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/media?parent=1548"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/categories?post=1548"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.xsofthost.com\/help\/wp-json\/wp\/v2\/tags?post=1548"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}