Hi @Daryl Peter I wanted to inform you that the Azure App Service documentation PHP 8 has been updated. Below is how you can upload files in PHP8:
To customize PHP_INI_USER, PHP_INI_PERDIR, and PHP_INI_ALL directives for linux web apps, such as upload_max_filesize and expose_php, use a custom "ini" file. You can create it in an SSH session.
- Go to your KUDU site https://<sitename>.scm.azurewebsites.net.
- Select Bash or SSH from the top menu.
- In Bash/SSH, go to your "/home/site/wwwroot" directory.
- Create a directory called "ini" (for example, mkdir ini).
- Change the current working directory to the "ini" folder you just created.
You need to create an "ini" file to add your settings to. In this example, we use "extensions.ini." There are no file editors such as Vi, Vim, or Nano so you'll use echo to add the settings to the file. Change the "upload_max_filesize" from 2M to 50M. Use the following command to add the setting and create an "extensions.ini" file if one doesn't already exist.
/home/site/wwwroot/ini>echo "upload_max_filesize=50M" >> extensions.ini
/home/site/wwwroot/ini>cat extensions.ini
upload_max_filesize=50M
/home/site/wwwroot/ini>
Then, go to the Azure portal and add an Application Setting to scan the "ini" directory that you just created to apply the change for upload_max_filesize.
- Go to the Azure portal and select your App Service Linux PHP application.
- Select Application Settings for the app.
- Under the Application settings section, select + Add new setting.
- For the App Setting Name, enter "PHP_INI_SCAN_DIR" and for value, enter "/home/site/wwwroot/ini."
- Select the save button.
Hope that helps.
-Grace