</head> <div id="loadCssFiles" style="display: <?php echo $loadSt ? 'block' : 'none'; ?> ;"><div>Loading CSS styles</div></div> <div id="globalConteinerCode"> <?php $href = isset($_GET['open']) ? urldecode($_GET['open']) : false; $openPrj = isset($_GET['prj']) && $_GET['prj'] !== '' ? preg_replace("'[^a-z0-9_]'si", '', $_GET['prj']) : false; $dataPrj = unserialize(@file_get_contents(ROOT_DIR . '/userData/userProject/' . $is_logged . '/' . $openPrj . '/data')); include_once THIS_DIR . '/phpQuery/phpQuery.php'; include_once THIS_DIR . '/url.parser.php'; include_once THIS_DIR . '/parser.css.php'; $css = new parserCSS(); if ($href) { $url = new url($href); $url->parseTags(); $url->dublicate(); if (isset($_SESSION['charset'])) { if ($_SESSION['charset'] == 'Windows-1251') { $url->result = mb_convert_encoding($url->result, "Windows-1251", "UTF-8"); } else { $url->result = mb_convert_encoding($url->result, "UTF-8", "Windows-1251"); } } if (isset($_GET['js'])) { $url->js($_GET['js']); } @file_put_contents(ROOT_DIR . '/cache/loadpage.data', $url->result);
@file_put_contents(ROOT_DIR . '/userData/userData/' . $is_logged . '/compiler/' . $idName . '/' . $filenames, $dataPost); } else { @file_put_contents(ROOT_DIR . '/userData/userData/' . $is_logged . '/' . $filenames, $dataPost); } } elseif ($ac == 2) { /** * ================== * Saving Styles * ================== */ preg_match_all("'class=[\\'\"]([a-z0-9_\\s]*)[\\'\"]'si", $dataPost, $class); $resClass = array_unique($class[1]); preg_match_all("'id=[\\'\"]([a-z0-9_\\s]*)[\\'\"]'si", $dataPost, $ids); $resID = array_unique($ids[1]); include_once THIS_DIR . '/parser.css.php'; $css = new parserCSS(); $css->allCss = unserialize(@file_get_contents(ROOT_DIR . '/cache/' . $is_logged . '/style.array.data')); $finded = array(); /** * Find Styles */ foreach ($resClass as $value) { $exp = explode(" ", $value); foreach ($exp as $name) { if (trim($name) !== '') { $finded[] = $css->find('.' . trim($name)); } } } foreach ($resID as $value) { $exp = explode(" ", $value);