IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası

IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası (https://www.ircforumlari.net/)
-   PHP (https://www.ircforumlari.net/php/)
-   -   php ile css dosyalarını sıkıştırmak css compress (https://www.ircforumlari.net/php/624438-php-ile-css-dosyalarini-sikistirmak-css-compress.html)

hAte 08 Ekim 2014 08:19

php ile css dosyalarını sıkıştırmak css compress
 
PHP- Kodu:

<?php
header
('Content-type: text/css');
ob_start("compress");
function 
compress($buffer) {
/* remove comments */
$buffer preg_replace('!/\*[^*]*\*+([^/][^*]*\*+)*/!'''$buffer);
/* remove tabs, spaces, newlines, etc. */
$buffer str_replace(array("\r\n""\r""\n""\t"' '' '' '), ''$buffer);
return 
$buffer;
}

/* your css files */
include('master.css');
include(
'typography.css');
include(
'grid.css');
include(
'print.css');
include(
'handheld.css');

ob_end_flush();
?>

Alıntıdır.


Tüm Zamanlar GMT +3 Olarak Ayarlanmış. Şuanki Zaman: 13:24.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO
Copyright ©2004 - 2025 IRCForumlari.Net Sparhawk