|
1 | | -<?php error_reporting(0); |
2 | | -// Root |
| 1 | +<?php error_reporting(E_ALL); |
| 2 | +// Security |
| 3 | +if (!defined('in_phpvibe')) |
| 4 | + define('in_phpvibe', true); |
| 5 | +// Root |
3 | 6 | if( !defined( 'ABSPATH' ) )$abs = str_replace( array('\\', '/app/minify'),array( '/',''), dirname( __FILE__ ) ); |
4 | | - define( 'ABSPATH', $abs ); |
5 | | -/* $full_link = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; */ |
6 | | -$full_link = (empty($_SERVER['HTTPS']) ? 'http' : 'https') . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; |
7 | | -$uri_parts = explode('css.php', $full_link, 2); |
8 | | -$site_link = $uri_parts[0];$site_link = str_replace('app/minify/', '', $site_link); |
| 7 | +define( 'ABSPATH', $abs ); |
| 8 | +//Include configuration |
| 9 | +require_once(ABSPATH . '/vibe_config.php'); |
| 10 | +$site_link = SITE_URL; |
9 | 11 | $themefold = isset($_GET['t']) ? $_GET['t'] : "main"; |
10 | 12 | $themefold = preg_replace('/(\.+\/)/','',$themefold); |
11 | 13 | $txt = ''; |
|
25 | 27 | // Set the correct MIME type, because Apache won't set it for us |
26 | 28 | header("Content-type: text/css"); |
27 | 29 | header('Pragma: public'); |
28 | | - // Write everything out |
| 30 | + // Write everything out |
29 | 31 | readfile($cachedfile); |
30 | 32 |
|
31 | 33 | /* $txt = file_get_contents($cachedfile); echo $txt; */ |
|
59 | 61 | $txt = preg_replace( '/(\/\*[\w\'\s\r\n\*\+\,\"\-\.]*\*\/)/', '$2', $txt ); |
60 | 62 | //A fix |
61 | 63 | $txt = str_replace('and(', 'and (', $txt); |
62 | | - $txt = "/* PHPVibe CMS | Copyright PHPVibe.com */ ".$txt; |
| 64 | + // Signature |
| 65 | + $txt = "/* Powered by the PHPVibe CMS ( PHPVibe.com ) */ ".$txt; |
63 | 66 |
|
64 | 67 |
|
65 | 68 | // Create cache file |
|
0 commit comments