Given a file URI, let's provide a helper on the existing File class to convert it to a data URI.

Comments

Dave Reid created an issue. See original summary.

dave reid’s picture

Status: Active » Needs review
StatusFileSize
new2.88 KB
dave reid’s picture

This also adds a Twig extension supporting a new file_data_uri() function.

Status: Needs review » Needs work

The last submitted patch, 3: 3179916-file-data-uri-with-twig-extension.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

dave reid’s picture

Status: Needs work » Needs review
StatusFileSize
new3.1 KB

Okay let's try without the Twig extension for now.

  • Dave Reid authored e1ac2d4 on 8.x-1.x
    Issue #3179916 by Dave Reid: Added File::getDataUri() for converting a...
dave reid’s picture

Status: Needs review » Fixed

Committed #5 to 8.x-1.x.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.