5) { if ($nb == 0) { $title = GetSQLValue("emag_articles", "title", "id_article = ".$_GET['id_article']); $title_eng = GetSQLValue("emag_articles", "title_eng", "id_article = ".$_GET['id_article']); $authors_eng = GetSQLValue("emag_articles", "authors_eng", "id_article = ".$_GET['id_article']); if ($lang == 2) $title = $title_eng; if($nb_itemid > 0) { $authors_for_title = $lang == 1 ? $authors : $authors_eng; $title = $authors_for_title." ".$title; } ShowTopPart($title, false, false, $_GET['id_article']); ShowMagColumn($mag, 0, 0, 1); } print($cached_content); if ($nb == 0) ShowBottomPart(); die(); } $printed = GetSQLValue("emag_articles", "printed", "id_article = ".$_GET['id_article']); $first_send_date = GetSQLValue("emag_articles", "first_send_date", "id_article = ".$_GET['id_article']); $review_start_date = GetSQLValue("emag_articles", "review_start_date", "id_article = ".$_GET['id_article']); $publish_date = GetPublishDate($_GET['id_article']);//GetSQLValue("emag_articles", "publish_date", "id_article = ".$_GET['id_article']); $article_year = GetSQLValue("emag_articles", "year", "id_article = ".$_GET['id_article']); /*if (!$article_year || $article_year >= 2015) { $id_article_original = GetSQLValue("emag_articles", "id_article_original", "id_article = ".$_GET['id_article']); if ($id_article_original == 0) { $id_article_original = $_GET['id_article']; } $first_send_real_date = GetSQLValue("actions_log", "action_time", "id_article = ".$id_article_original . " ORDER BY action_time LIMIT 1"); if ($publish_date != '0000-00-00 00:00:00') { $first_send_real_date = strtotime($publish_date) > (strtotime($first_send_real_date) + 60 * 60 * 24 * 7) ? $first_send_real_date : (date('Y-m-d H:i:s', strtotime($publish_date) - 60 * 60 * 24 * 7)); } $id_article_originaldb = GetSQLValue("emag_articles", "id_article_original", "id_article = ".$_GET['id_article']); if ($id_article_originaldb != 0) { $first_send_real_date = $review_start_date; } }*/ $first_send_real_date = GetFirstSendRealDate($_GET['id_article']); if ($review_start_date == "2013-01-01 00:00:00") { $review_start_date = new DateTime($first_send_date); $review_start_date->modify('+1 day'); $review_start_date = $review_start_date->format('Y-m-d H:i:s'); } if ( ($printed == 0) && ($status != 7) && (!isset($_GET['preprint'])) && (!isset($_GET['short'])) && (!isset($_GET['preview'])) && (!isset($_GET['pdf']))) { die("Статья еще не опубликована!"); } mysql_query("UPDATE emag_articles SET visit_count = visit_count + 1 WHERE id_article=".$_GET['id_article']); DBDisconnect(); $table = 'emag_articles'; $condition = 'id_article = '.$_GET['id_article']; if (isset($_GET['editor']) && $_GET['editor'] == 1) { CheckLoggedUserPriveledges(); CheckUnconfirmedUser(); } else { $condition .= " AND status >= 0 "; } if ((isset($_GET['id_version'])) && (is_numeric($_GET['id_version']))) { $table .= '_versions'; $condition .= ' AND id_version = '.$_GET['id_version']; } if ($lang == 2) { DBConnect(); $en_content = GetSQLValue("emag_articles", "en_content", "id_article = ".$_GET['id_article']); $common_length = strlen($en_content); $checking = true; $needToUpdate = false; if (strlen($en_content) > 5) { if (strpos($en_content,"??") !== false) { for($i=20; $i >1; $i--) { $ques_sym = ""; for($j=0; $j<$i; $j++) { $ques_sym.="?"; } $en_content = str_replace($ques_sym,"",$en_content); } $find4 = '">?'; $en_content = str_replace($find4,'">',$en_content); $needToUpdate = true; } while ($checking == true) { $pos1 = strripos($en_content, "

 

strripos while ($checking == true) { $pos1 = strrpos($en_content, $find1); $pos2 = strrpos($en_content, $find2); $pos3 = strrpos($en_content, $find3); //print('pos1 = '.$pos1); //print('pos2 = '.$pos2); //print '*'.$en_content[$pos1 + strlen($find1)].'*'; if ($pos1 === false && $pos2 === false && $pos3 == false) { $checking = false; } else if ( $pos1 !== false && ($common_length - $pos1) < 120) { $en_content = substr($en_content, 0, $pos1); $common_length = strlen($en_content); //print('pos 1 replace = '); $needToUpdate = true; } else if( $pos2 !== false && (($common_length - $pos2) < 140) ) { $en_content = substr($en_content, 0, $pos2); $common_length = strlen($en_content); //print('pos 2 replace = '); $needToUpdate = true; } else if( $pos3 !== false && (($common_length - $pos3) < 10) ) { $en_content = substr($en_content, 0, $pos3); $common_length = strlen($en_content); //print('pos 2 replace = '); $needToUpdate = true; } else { $checking = false; } }*/ //print($en_content); //die(); if ($needToUpdate == true) DoUpdateQuery('emag_articles', array('en_content'), array(OnlyEscape($en_content)), "id_article = ".$_GET['id_article']); } } $article = new CArticle($table, $condition, array('content', 'en_content', 'annotation', 'grants_info', 'annotation_eng','annotation_cn', 'review', 'review_cost', 'reviewer_decision', 'exclude_author', 'id_mag', 'id_user', 'year', 'month', 'uni_logo', 'uni_site', 'id_article','udk','secondary_biblio','printed','document_type', 'lang_text', 'visit_count','publish_date','first_send_date','start_time_generate_doc','is_eng_text_published','edn','last_crossref_check_time','is_auto_translated','nb_itemid','with_pdf','retraction_text'), 'article_page/'); $article->AddHelperQuery('SELECT issn FROM emag_mags WHERE id_mag={id_mag}'); $article->AddHelperQuery('SELECT id_order as id_order_payed_subscribe FROM emag_orders WHERE id_article={id_article} AND order_type=22 AND id_user='.$_SESSION['id_user'].' AND is_payed=1'); $article->GetInfoIfNeeded(); DBConnect(); // $mag_info = GetRecordSet("emag_mags", array('title', 'title_eng','title_cn','aurora_only'), "id_mag = ".$article->GetValue("id_mag")); if ($mag_info[0]['aurora_only'] == 1) { $lang = 2; } $title = $article->GetValue($lang == 1 ? "title" : "title_eng"); if (!isset($_GET['short']) && !isset($_GET['pdf']) && !isset($_GET['nb'])) { if($nb_itemid > 0) { $authors_for_title = $article->GetValue($lang == 1 ? "authors" : "authors_eng"); $title = $authors_for_title." ".$title; } ShowTopPart($title, false, false, $_GET['id_article']); } $tFilter = new CTransliterationFilter(); DBConnect(); $article_info = GetRecordSet("emag_articles", array('title', 'title_eng', 'title_cn', 'authors', 'authors_eng', 'page_start', 'page_end','nb_itemid','free','id_article_original'), "id_article = ".$_GET['id_article']); // $free = GetSQLValue("emag_articles", "free", "id_article = ".$_GET['id_article']); $keywords = GetRecordSet('emag_keywords', array('keyword'), 'id_article = '.$_GET['id_article']." ORDER BY id_keyword ASC"); $keywordsEng = GetRecordSet('emag_keywords_eng', array('keyword'), 'id_article = '.$_GET['id_article']." ORDER BY id_keyword ASC"); $keywordsCn = GetRecordSet('emag_keywords_cn', array('keyword'), 'id_article = '.$_GET['id_article']." ORDER BY id_keyword ASC"); $links = GetRecordSet('emag_bibliolinks', array('link'), 'id_article = '.$_GET['id_article'].' ORDER BY id_link ASC'); $links_eng = GetRecordSet('emag_bibliolinks_eng', array('link'), 'id_article = '.$_GET['id_article'].' ORDER BY id_link ASC'); $crossref = GetRecordSet('emag_crossref', array('*'), 'id_article = '.$_GET['id_article'].' ORDER BY id_ref ASC'); if (count($links_eng) == 0) { for ($i = 0; $i < count($links); $i++) { $link_eng = $tFilter->rus2translit($links[$i]['link']); $link_eng = str_replace("\n", "
", $link_eng); $link_eng = str_replace("\r", "
", $link_eng); $links_eng[] = array('link' => $link_eng); } } $reviewHistory = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $_GET['id_article'] . ' AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); $reviewHistoryEng = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review_eng', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $_GET['id_article'] . ' AND LENGTH(review_eng) > 5 AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); if (count($reviewHistory) == 0 && $article_info[0]['id_article_original'] > 0) { $reviewHistory = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $article_info[0]['id_article_original'] . ' AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); if (count($reviewHistory) == 0) { $id_article_original_2 = GetSQLValue("emag_articles", "id_article_original", "id_article = ".$article_info[0]['id_article_original']); if ($id_article_original_2 > 0) { $reviewHistory = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $id_article_original_2. ' AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); } } } if (count($reviewHistoryEng) == 0 && $article_info[0]['id_article_original'] > 0) { $reviewHistoryEng = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review_eng', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $article_info[0]['id_article_original']. ' AND LENGTH(review_eng) > 5 AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); if (count($reviewHistoryEng) == 0) { $id_article_original_2 = GetSQLValue("emag_articles", "id_article_original", "id_article = ".$article_info[0]['id_article_original']); if ($id_article_original_2 > 0) { $reviewHistoryEng = GetRecordSet( 'emag_review_history LEFT JOIN emag_users ON emag_review_history.id_review_user = emag_users.id_user', array('emag_review_history.id_review_history', 'emag_review_history.review_eng', 'emag_users.name', 'emag_users.middlename', 'emag_users.surname', 'emag_users.summary', 'emag_users.science_degree'), 'id_article = ' . $id_article_original_2. ' AND LENGTH(review_eng) > 5 AND status = 1 AND review_cost >= 100 ORDER BY review_start_date ASC' ); } } } while (count($reviewHistory) > 3) { array_shift($reviewHistory); } while (count($reviewHistoryEng) > 3) { array_shift($reviewHistoryEng); } $id_mag = $article->GetValue("id_mag"); $month = $article->GetValue("month"); $year = $article->GetValue("year"); $review = $article->GetValue("review"); $issue_date = GetIssueDate($_GET['id_article']); /*$dt = GetSQLValue('emag_issues', 'issue_done_date', 'id_mag='.$id_mag.' AND month = '.$month." AND year = ".$year." AND partial = 0"); $issue_date = GetRussianDate($dt); if (($issue_date == '01-01-2013') || ($issue_date == '00-00-0000')) { $cnt = GetRecordsCount('emag_issues', 'id_mag='.$id_mag.' AND year = '.$year); $mnth = $month * 12 / $cnt; $issue_date = '1-'.$mnth.'-'.$year; }*/ if ($lang == 2 && count($links_eng)) { $links = $links_eng; } $biblio_eng = $tFilter->rus2translit($article->GetValue("secondary_biblio")); $biblio_eng = str_replace("\n", "
", $biblio_eng); $biblio_eng = str_replace("\r", "
", $biblio_eng); $authors = UpdateAuthors($_GET['id_article']); for ($i = 0; $i < count($authors); $i++) { if (isset($authors[$i]['id_coauthor'])) { $aut = GetRecordSet("emag_coauthors", array("*"), 'id_coauthor='.$authors[$i]['id_coauthor']); //$authors[$i] = $aut[0]; $other_articles = GetRecordSet("emag_coauthors_by_article", array("*"), 'id_coauthor='.$authors[$i]['id_coauthor'].' AND id_article != '.$_GET['id_article']); $cnt = 0; for($j = 0; $j < count($other_articles); $j++) { $status_other = GetSQLValue('emag_articles', 'status', 'id_article='.$other_articles[$j]['id_article']); if ($status_other == 7) { $cnt = 1; break; } } $authors[$i]['another_articles_cnt'] = $cnt; } else { $aut = GetRecordSet("emag_users", array("*"), 'id_user='.$authors[$i]['id_user']); //$authors[$i] = $aut[0]; $cnt = GetRecordsCount('emag_articles', 'id_user='.$authors[$i]['id_user'].' AND id_article != '.$_GET['id_article'].' AND status = 7'); $authors[$i]['another_articles_cnt'] = $cnt; } if (($uni_name == '') && (strlen($authors[$i]['work_university']) > 0)) { $uni_name = $authors[$i]['work_university']; } $fileName = '';; if (isset($authors[$i]['id_coauthor'])) { $fileName = 'img/coauthors/'.$authors[$i]['id_coauthor'].'.jpg'; } else { $fileName = 'img/authors/'.$authors[$i]['id_user'].'.jpg'; } if (!file_exists($fileName)) { $fileName = '/img/no_photo.png'; } else { $fileName = '/'.$fileName; } $authors[$i]['photo'] = $fileName; if ($lang == 2 || $lang == 3) { if (strlen($authors[$i]['surname_eng']) > 5) $authors[$i]['surname'] = $authors[$i]['surname_eng']; else $authors[$i]['surname'] = $tFilter->rus2translit($authors[$i]['surname']); if (strlen($authors[$i]['name']) > 5) $authors[$i]['name'] = $authors[$i]['name_eng']; else $authors[$i]['name'] = $tFilter->rus2translit($authors[$i]['name']); if (strlen($authors[$i]['middlename']) > 5) $authors[$i]['middlename'] = $authors[$i]['middlename_eng']; else $authors[$i]['middlename'] = $tFilter->rus2translit($authors[$i]['middlename']); $authors[$i]['middlename'] = $tFilter->rus2translit($authors[$i]['middlename']); if ($lang == 3) $authors[$i]['science_degree'] = GetCnDegree($authors[$i]['science_degree']); else $authors[$i]['science_degree'] = GetEnglishDegree($authors[$i]['science_degree']); } $authors[$i]['science_degree_eng'] = GetEnglishDegree($authors[$i]['science_degree']); if (strlen($authors[$i]['contact_address_eng']) < 5) { $address = $authors[$i]['contact_address']; $address = str_replace("Россия","Russia",$address); $address = str_replace("Российская Федерация","Russia",$address); $address = str_replace("Российская федерация","Russia",$address); $address = str_replace("Москва","Moscow",$address); $address = str_replace("Санкт-Петербург","Saint Petersburg",$address); $authors[$i]['contact_address_eng'] = $tFilter->rus2translit($address); } } $id_rubric = GetSQLValue('emag_articles', 'id_rubric', 'id_article='.$_GET['id_article']); $rubric = GetSQLValue('emag_rubrics', 'title', 'id_rubric='.$id_rubric); $rubric_eng = GetSQLValue('emag_rubrics', 'title_eng', 'id_rubric='.$id_rubric); $online_for_registered_price = GetSQLValue('emag_prices', 'price', "id_price = 9"); $online_for_all_price = GetSQLValue('emag_prices', 'price', "id_price = 10"); $article_subscription_price = GetSQLValue('emag_prices', 'price', "id_price = 22 AND service_type='article_subscription'"); DBDisconnect(); $rubricLower = strtolower($rubric); $is_editor_column = 0; /*if (strrpos($rubricLower,'колонка главного редактора') !== false) { $is_editor_column = 1; }*/ if (!isset($_GET['short']) && !isset($_GET['pdf']) && !isset($_GET['nb'])) { ShowMagColumn($mag, 0, 0, 1); } if (isset($_GET['short']) || isset($_GET['pdf']) || isset($_GET['preview']) || isset($_GET['nb'])) $free = 2; $year = $article->GetValue('year'); $month = $article->GetValue('month'); if ($lang == 1) { $journalT = "Журнал"; $contentsT = 'Содержание № '.$month.' за '.$year.' год'; if ($issue_date != '') { $contentsT .= '('.$issue_date.')'; } $titleT = $article->GetValue("title"); $back = "Вернуться к содержанию"; } else { $journalT = "Journal"; $contentsT = 'Contents of Issue № '.$month.'/'.$year; $titleT = $article->GetValue("title_eng"); $back = "Back to contents"; } //if ($article_year && $article_year < 2015) { // $first_send_real_date = date('Y-m-d H:i:s', strtotime($issue_date) - 60 * 60 * 24 * 14); //} switch ($_GET['id_article']) { case 36211: $first_send_real_date = '2021-08-02 00:00:00'; break; } $host_name ='//'.$_SERVER['HTTP_HOST'] ; //$article->AddConst("breadcrumbs", array(array("title" => $journalT.' "'.GetMagTitle($mag).'"', "url" => '/'.$mag.'/'), //array("title" => $contentsT, "url" => '/'.$mag.'/contents_'.$year.'_'.$month.'.html'), //array("title" => $titleT, "url" => '/'.$mag.'/article_'.$_GET['id_article'].'.html'))); $article->AddConst("breadcrumbs", array(array("title" => $back, "url" => '/'.$mag.'/contents_'.$year.'_'.$month.'.html'))); //array("title" => $contentsT, "url" => '/'.$mag.'/contents_'.$year.'_'.$month.'.html'), //array("title" => $titleT, "url" => '/'.$mag.'/article_'.$_GET['id_article'].'.html'))); $cf = new CArticleFilter(); $img_translated = array(); $original_images = array(); $original_images_click = array(); if ($lang == 2) { DBConnect(); $img_translated = GetRecordSet('emag_articles_translated_images', array('*'), 'id_article='.$_GET['id_article']); DBDisconnect(); preg_match_all('/]+>/i',$article->GetValue("content"), $matches); if (count($matches) > 0) { $original_images = $matches[0]; } } else { preg_match_all('/]+>/i',$article->GetValue("content"), $matches); if (count($matches) > 0) { $original_images_click = $matches[0]; } } //print_r($original_images_click); $cf->replacements = $img_translated; $cf->original_images = $original_images; $cf->original_images_click = $original_images_click; $article->AddFieldFilter('content', $cf); $article->AddFieldFilter('en_content', $cf); $article->AddFieldFilter('annotation', new CAnnotationFilter()); $article->AddFieldFilter('annotation_eng', new CAnnotationFilter()); $article->AddFieldFilter('secondary_biblio', new CBiblioFilter()); $article->AddConst('keywords', ($lang == 1) ? $keywords : $keywordsEng); $article->AddConst('keywordsEng', $keywordsEng); $article->AddConst('keywordsCn', $keywordsCn); $article->AddConst('status', $status); $article->AddConst('links', $links); // // $article_title = !preg_match('/( г\.| гг\.| в\.| вв\.)$/', $article_info[0]['title']) ? rtrim(trim($article_info[0]['title']), '.') : $article_info[0]['title']; $article_title = $article_info[0]['title']; $article_title_eng = $article_info[0]['title_eng']; $article_title_nb = ""; $article_title_eng_nb = ""; if($article_info[0]['nb_itemid'] > 0) { $free = $article_info[0]['free']; $article_title_nb = $article_info[0]['authors']." ".$article_title; $article_title_eng_nb = $article_info[0]['authors_eng']." ".$article_title_eng; } $article->AddConst('title_nb', $article_title_nb); $article->AddConst('title_eng_nb', $article_title_eng_nb); $article->AddConst('title', $article_title); $article->AddConst('title_eng', $article_title_eng); $article->AddConst('title_cn', $article_info[0]['title_cn']); $article->AddConst('ru_mag_title', $mag_info[0]['title']); $article->AddConst('en_mag_title', $mag_info[0]['title_eng']); $article->AddConst('cn_mag_title', $mag_info[0]['title_cn']); $article->AddConst('aurora_only', $mag_info[0]['aurora_only']); $article->AddConst('ru_authors', $article_info[0]['authors']); $article->AddConst('en_authors', $article_info[0]['authors_eng']); $article->AddConst('page_start', $article_info[0]['page_start']); $article->AddConst('page_end', $article_info[0]['page_end']); $article->AddConst('nb_itemid', $article_info[0]['nb_itemid']); // $article->AddConst('host_name', $host_name); $article->AddConst('links_eng', $links_eng); $article->AddConst('biblio_eng', $biblio_eng); $article->AddConst('authors', $authors); $article->AddConst('uni_name', $uni_name); $article->AddConst('short', isset($_GET['short']) ? 1 : 0); $article->AddConst('pdf', isset($_GET['pdf']) ? 1 : 0); $article->AddConst('nb', isset($_GET['nb']) ? 1 : 0); $article->AddConst('logged_nb', isset($_GET['logged']) ? $_GET['logged'] : 0); $article->AddConst('aurora', isset($_GET['aurora']) ? $_GET['aurora'] : 0); $article->AddConst('anonym', isset($_GET['anonym']) ? 1 : 0); $article->AddConst('lang', $lang); $article->AddConst('rus_link', str_replace('en.', '', GetCurrentURL())); $article->AddConst('cur_link', urlencode(GetCurrentURL())); $article->AddConst('redirect_to_order', urlencode("author_make_order.php?id=9&id_article=".$_GET['id_article'])); $article->AddConst('link_to_arcticle', GetLinkToArcticle($_GET['id_article'])); $article->AddConst('rubric', $rubric); $article->AddConst('rubric_eng', $rubric_eng); $article->AddConst('id_rubric', $id_rubric); $article->AddConst('show_keyword_link', ((isset($_SESSION['id_user'])) && (($_SESSION['id_user'] == 16) || ($_SESSION['id_user'] == 18) || ($_SESSION['id_user'] == 37)))); $article->AddConst('show_articles_link', ((isset($_SESSION['user_type'])) && (($_SESSION['user_type'] == -1) || ($_SESSION['user_type'] == 6))) ); $article->AddConst('preview', isset($_GET['preview']) ? 1 : 0); $article->AddConst('user_type', isset($_SESSION['user_type']) ? $_SESSION['user_type'] : 0); $article->AddConst('logged', IsLoggedUser() ? 1 : 0); $article->AddConst('online_for_registered_price', $online_for_registered_price); $article->AddConst('online_for_all_price', $online_for_all_price); $article->AddConst('article_subscription_price', $article_subscription_price); $article->AddConst('free', $free); $article->AddConst('is_editor_column', $is_editor_column); $article->AddConst('isDirector', $isDirector); $article->AddConst('issue_date', $issue_date); $article->AddConst('doi', GetFullDOI($_GET['id_article'])); $article->AddConst('review', $review); $article->AddConst('review_start_date', $review_start_date); $article->AddConst('first_send_real_date', $first_send_real_date); $article->AddConst('reviewHistory', $reviewHistory); $article->AddConst('reviewHistoryEng', $reviewHistoryEng); $article->AddConst('crossref', $crossref); $article->AddConst('idr', rand(0, 10000000)); if ( isset($_GET['pdf']) || isset($_GET['nb'])) { $main_css = file_get_contents("M:\\home\\e-notabene.ru\\www\\css\\main.css"); $article->AddConst('main_css', $main_css); } if (!isset($_GET['short']) && !isset($_GET['pdf']) && !isset($_GET['preview'])) if ($status == 7 ) { $post_fix = "ru"; if ($lang == 2) $post_fix = "en"; elseif ($lang == 3) $post_fix = "cn"; if ($nb == 1 && $aurora == 1 && strlen($article->GetValue("au_cached_content_".$post_fix)) < 5) { $cached_content = $article->GetAsText(); DBConnect(); DoUpdateQuery('emag_articles', array('au_cached_content_'.$post_fix), array(OnlyEscape($cached_content)), 'id_article ='.$_GET['id_article']); DBDisconnect(); } elseif ($nb == 1 && strlen($article->GetValue("nb_cached_content_".$post_fix)) < 5) { $cached_content = $article->GetAsText(); DBConnect(); DoUpdateQuery('emag_articles', array('nb_cached_content_'.$post_fix), array(OnlyEscape($cached_content)), 'id_article ='.$_GET['id_article']); DBDisconnect(); } elseif (strlen($article->GetValue("e_cached_content_".$post_fix)) < 5) { $cached_content = $article->GetAsText(); DBConnect(); DoUpdateQuery('emag_articles', array('e_cached_content_'.$post_fix), array(OnlyEscape($cached_content)), 'id_article ='.$_GET['id_article']); DBDisconnect(); } } $article->Show(); if (!isset($_GET['short']) && !isset($_GET['pdf']) & !isset($_GET['nb'])) { ShowBottomPart(); } ?>