'.date('Y-m-d', strtotime($row['publish_date'])).'

'; $backButton = 'Grįžti į naujienas'; break; } } } // Projects if(empty($ID)) { $row_query=mysql_query("SELECT * FROM `content_projects`"); while($row=mysql_fetch_assoc($row_query)) { if(getURL("project", $row['ID']) == $URL) { $ID = $row['ID']; // ID $title = $row['title']; // Title $text = $row['text']; // Text $author = $row['author']; // Author $seo_title = $row['seo_title']; // SEO title $seo_description = $row['seo_description']; // SEO description $seo_keywords = $row['seo_keywords']; // SEO keywords $backButton = 'Grįžti į atgal'; break; } } } // Catalog if(empty($ID)) { $row_query=mysql_query("SELECT * FROM `content_catalogs` WHERE parentID='0'"); while($row=mysql_fetch_assoc($row_query)) { if(getURL("catalog", $row['ID']) == $URL) { $ID = $row['ID']; // ID $title = $row['title']; // Title $text = $row['text']; // Text $seo_title = $row['seo_title']; // SEO title $seo_description = $row['seo_description']; // SEO description $seo_keywords = $row['seo_keywords']; // SEO keywords $catalog = true; break; } } } // Promotion if(empty($ID)) { $row_query=mysql_query("SELECT * FROM `content_promotions` WHERE parentID='0'"); while($row=mysql_fetch_assoc($row_query)) { if(getURL("promotion", $row['ID']) == $URL) { $ID = $row['ID']; // ID $title = $row['title']; // Title $text = $row['text']; // Text $seo_title = $row['seo_title']; // SEO title $seo_description = $row['seo_description']; // SEO description $seo_keywords = $row['seo_keywords']; // SEO keywords $promotion = true; break; } } } // Sub-catalog if(empty($ID)) { $row_query=mysql_query("SELECT * FROM `content_catalogs` WHERE parentID>'0'"); while($row=mysql_fetch_assoc($row_query)) { if(getURL("subCatalog", $row['ID']) == $URL) { $ID = $row['ID']; // ID $title = $row['title']; // Title $text = $row['text']; // Text $seo_title = $row['seo_title']; // SEO title $seo_description = $row['seo_description']; // SEO description $seo_keywords = $row['seo_keywords']; // SEO keywords break; } } } // Sub-promotion if(empty($ID)) { $row_query=mysql_query("SELECT * FROM `content_promotions` WHERE parentID>'0'"); while($row=mysql_fetch_assoc($row_query)) { if(getURL("subPromotion", $row['ID']) == $URL) { $ID = $row['ID']; // ID $title = $row['title']; // Title $text = $row['text']; // Text $seo_title = $row['seo_title']; // SEO title $seo_description = $row['seo_description']; // SEO description $seo_keywords = $row['seo_keywords']; // SEO keywords $subpromotion = true; break; } } } // Security if(empty($ID)) { // Sending to 404 page header('Location: '.BASEURL.'404'); exit; } // Only for 404 page if($URL == 404) { header("HTTP/1.1 404 Not Found"); } ?> <?=$seo_title?>

'.$row['title'].'
'; } echo ''; } elseif($promotion && MQ_count("content_promotions", "WHERE parentID='".$ID."'")) { $row_query=mysql_query("SELECT * FROM `content_promotions` WHERE parentID='".$ID."' ORDER BY position"); while($row=mysql_fetch_assoc($row_query)) { $cats .= '
  • '.$row['title'].'
  • '; } echo ''; } elseif ( $subpromotion && mysql_num_rows(mysql_query("SELECT * FROM `content_albums` LEFT JOIN `_assigns` ON (_assigns.assignID=content_albums.ID AND _assigns.contentID='".$ID."') WHERE _assigns.contentID='".$ID."'")) ) { $row_query=mysql_query("SELECT * FROM `content_albums` LEFT JOIN `_assigns` ON (_assigns.assignID=content_albums.ID AND _assigns.contentID='".$ID."') WHERE _assigns.contentID='".$ID."'"); while($row=mysql_fetch_assoc($row_query)) { $row_query2=mysql_query('SELECT * FROM `content_images` LEFT JOIN `_assigns` ON (_assigns.assignID=content_images.ID) WHERE _assigns.contentID=\''.$row['ID'].'\' ORDER BY content_images.position '); while($row2=mysql_fetch_assoc($row_query2)) { // $i++; // Images in list $images[$row['ID']] .= '
    '.$row2['title'].'
    '; } $cat .= '
  • '.$row['title'].'
    '.$images[$row['ID']].'
  • '; } echo ''; } else { // Gallery echo gallery($ID); } // Publish date echo $publish_date; // Back link echo $backButton; if($ID == 372) { // Contact form echo formContact(); } elseif($ID == 384) { // News list echo newsList(); } elseif($ID == 512) { // Projects list echo projectList(); } elseif($ID == 385) { // Main catalogs list echo catsList(); } elseif($ID == 383) { // Main promotions list echo promoList(); } ?>