Upload pictures in code Blog

Mar 21, 2014 at 8:52 AM

What is the best solution for optimum performance, images embedded in the html editor (src = "data: image / png; base64) or load them with" <img src = "/ pics /".

Mar 24, 2014 at 12:24 PM
I think you have pro and cons: embending images with {data:image/png...} could be usefull for small images (like invisibile pixel gif/png): it reduce number of http request but don't go in browser's cache. Otherwise, with {img src="..."} you add one (or more) http request but a second request of the same image dosen't reload because it is cached. this second option is more suitable by default for images that repeat over a website (logo, header, footer, background) instead data:image (my opinion) is more suitable for single small images.
Mar 24, 2014 at 5:45 PM
thanks for your opinion, I will follow your advice and I will apply either method depending
on the weight and use of images.