1 February
Functions file_create_url() not working in Drupal 10
By: admin | Published On: Thu, 02/01/2024 - 11:44
Functions file_create_url() was using to create url of images and files drupal 9 but now its not working in Drupal 10 so its deprecated now you can use code as follow to create url in Drupal 10
\Drupal::service('file_url_generator')->generateAbsoluteString($uri);
Used in Drupal 9 and before Using Drupal 10 file_create_url($uri) \Drupal::service('file_url_generator')->generateAbsoluteString($uri)…