![]() |
Gzip in pages? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Gzip in pages? (/showthread.php?tid=4785) |
Gzip in pages? - El Forum - 12-15-2007 [eluser]Lovecannon[/eluser] Okay, Im using this to GZIP my pages... Code: function acceptsGZip(){ Gzip in pages? - El Forum - 12-16-2007 [eluser]Lovecannon[/eluser] I fixed everything, so cancel this Gzip in pages? - El Forum - 12-16-2007 [eluser]AtlantixMedia[/eluser] can you share your solution? I will soon need to do this as well. thanks Gzip in pages? - El Forum - 12-16-2007 [eluser]Lovecannon[/eluser] Well apparently, the function I was using for GZIP wasn't working, so I just used PHPs build in ob_gzhandler, so just add this at the far beginning (Before any HTML) of any view you want GZIPped Code: <?php Code: ob_start("ob_gzhandler"); Gzip in pages? - El Forum - 12-16-2007 [eluser]AtlantixMedia[/eluser] ok, just a regular ob_start("ob_gzhandler"); then. thanks Gzip in pages? - El Forum - 12-16-2007 [eluser]Lovecannon[/eluser] No prob. Gzip in pages? - El Forum - 12-16-2007 [eluser]alexsancho[/eluser] I don't know if i'm loosing anything here, but.. why not simply enable it on config and let CI do the job? Code: /* Gzip in pages? - El Forum - 12-16-2007 [eluser]AtlantixMedia[/eluser] this is even better. thanks!. new to CI... Gzip in pages? - El Forum - 12-16-2007 [eluser]Lovecannon[/eluser] I completely forgot about the built in compressor -_-'. I feel like an idiot now lol. |