Forum Discussion
Kevin_Stewart
May 02, 2013Employee
I would recommend a slightly different approach. Create a single data group with all of your base64-encoded image content, indexed with the name of the image.
ex.
logo.png := /9j/4AAQSkZJRgABAQEASABIAAD/4QDSR...
offlineimage.png := DEBAgALAAAASgAAADIBAgAUAA...
Then use iRule logic like the following:
if { [HTTP::uri] ends_with "/logo.png" } {
HTTP::respond 200 content [b64decode [class lookup "logo.png" image_class]] "Content-Type" "image/png"
}