Optimize OpenX Banner delivery by using Data URIs
Recently I tried to further optimize it by displaying base64 encoded banners by using Data URI schemes. Data URI schemes gives you option to embed objects like images in your HTML thus it helps to save requests you need make to fetch image. Though it increase the size by 33% but it gets reduced if your apache server is mod gzip/deflate enabled. Base64 encoded URIs are supported in modern browsers like FireFox v 3.x,Safari > 9 ,Chrome,Internet Explorer > 7.
First of all I modified the code in admin area. What all I did that i read the file after it gets uploaded, converted into base64 and saved it in db. After successful operation I removed physical image from db thus it was quite useless now. Later I modified query to fetch Banners and changed image URL in delivery/spc.php so that it delivers base64 encoded image. That's it! With this change you can save your precious bandwidth and request and can serve images faster. If you are a developer and concerned about performance then you should sure give it a try.
P.S: I myself provided consultancy for OpenX. In minimal charges I can help you to speed up your banner delivery on your site. For contact just drop your mail at kadnan(AT)gmail(dot)com