https://api.drupal.org/api/drupal/core%21includes%21file.inc/function/fi...
Transforms an absolute URL of a local file to a relative URL.
May be useful to prevent problems on multisite set-ups and prevent mixed content errors when using HTTPS + HTTP.
Parameters string
$file_url
: A file URL of a local file as generated byfile_create_url()
.Return value string If the file URL indeed pointed to a local file and was indeed absolute, then the transformed, relative URL to the local file. Otherwise: the original value of
$file_url
.
Recent comments
Thanks! The site was on PHP 7.0. With assistance from my hosting provider, I updated to PHP 7.4 and now I have access to the site again. No database re-import required.
Locked out of site after updating modules
Thank you very much. I will follow your advice.
Locked out of site after updating modules
The best you can do is test and report. If you find a contrib that doesn't work in php 8.3, create an issue in its queue so it gets fixed. In my experience, I've found that 7.4 is safest...
Locked out of site after updating modules