# [23-Nov-2025 05:36:07] /bros/www/ 113.196.59.51

set names utf8

SELECT
                *
	        FROM
	        	`meta`
                INNER JOIN `pages` ON
                    `pages`.`ID` = `meta`.`ID` AND
                    `pages`.`Language` = `meta`.`Language`
	    	WHERE
                `meta`.`Language` = 'bg' AND
                `meta`.`Module` = 'pages' AND
	    		`meta`.`URLLabel` = 'index'
         AND `meta`.`Visible` = 1 LIMIT 1

SELECT
                P2.`Language`,
                P2.`URLLabel`
            FROM
                `meta` AS P1
                INNER JOIN `meta` AS P2 ON
                    P1.`ID` = P2.`ID` AND
                    P1.`Module` = P2.`Module` AND
                    P2.`NoIndex` = 0 AND
                    P2.`Language` != 'bg' AND
                    P2.`Visible` = 1
            WHERE
                P1.`NoIndex` = 0 AND
                P1.`Module` = 'pages' AND
                P1.`Language` = 'bg' AND
                P1.`URLLabel` = 'index' AND
                P1.`Visible` = 1

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('LDestination','LDates','LGuestsNum','LSearch') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('ErrorLocation','ErrorDates','ErrorNumber') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                `bros_properties`.`propertyid`,
                `bros_properties`.`rating`,
                `bros_properties`.`name`,
                `bros_properties`.`image`,
                CONCAT_WS(', ', `bros_locations`.`name`, `bros_locations`.`region`, `bros_locations`.`country`) AS `Location`,
                `bros_property_description`.`Description`
            FROM
                `bros_properties`
                INNER JOIN `bros_locations` ON
                    `bros_properties`.`locationid` = `bros_locations`.`locationid`
                LEFT JOIN `bros_property_description` ON
                    `bros_properties`.`propertyid` = `bros_property_description`.`PropertyID` AND
                    `bros_property_description`.`Language` = 'bg'
            WHERE
                `bros_properties`.`propertyid` IN ('3','4','5')

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('LFeatured') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                `bros_properties`.`data`
            FROM
                `bros_properties`
            WHERE
                `propertyid` = 3
            LIMIT 1

SELECT * FROM `bros_property_description` LIMIT 1

SHOW COLUMNS FROM `bros_property_description`

REPLACE INTO `bros_property_description` SET `PropertyID` = 3, `Language` = 'bg', `Description` = 'Закътани в скрит малък залив близо до село Платария, сред зеленината ще откриете разпръснати ниски бунгала, спускащи се към невероятния пясъчен плаж.'

SELECT
                `bros_properties`.`data`
            FROM
                `bros_properties`
            WHERE
                `propertyid` = 4
            LIMIT 1

SELECT * FROM `bros_property_description` LIMIT 1

SHOW COLUMNS FROM `bros_property_description`

REPLACE INTO `bros_property_description` SET `PropertyID` = 4, `Language` = 'bg', `Description` = 'Разположен на идеално място, на брега на морето, заобиколен от тишината и спокойствието на боровата гора, на популярния полуостров Касандра, Al Mare предлага всички удобства за семейна почивка.'

SELECT
                `bros_properties`.`data`
            FROM
                `bros_properties`
            WHERE
                `propertyid` = 5
            LIMIT 1

SELECT * FROM `bros_property_description` LIMIT 1

SHOW COLUMNS FROM `bros_property_description`

REPLACE INTO `bros_property_description` SET `PropertyID` = 5, `Language` = 'bg', `Description` = 'На върха на красив залив, сред борова гора, хотел Александър Велики предлага интимна атмосфера, приятелски настроен персонал и вкусни деликатеси от местната кухня.'

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('LReadMore') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC

SELECT
                `Content`,
                `Limit`
            FROM
                `blocks`
            WHERE
                `Language` = 'bg' AND
                `Module` = 'articles' AND
                `Action` = 'home'
         AND `Visible` = 1 LIMIT 1

SELECT
                `meta`.`ID`,
                `meta`.`PostDate`,
                `meta`.`UploadID`,
                `articles`.`Image`,
                CONCAT(`Parent`.`URLLabel`, '/', `meta`.`URLLabel`) AS `URLLabels`,
                `articles`.`Title`,
                `articles`.`Annotation`,
                `meta`.`Visible`
            FROM
                `articles`
                INNER JOIN `meta` ON
                    `articles`.`ID` = `meta`.`ID` AND
                    `articles`.`Language` = `meta`.`Language` AND
                    `meta`.`Module` = 'articles'
                INNER JOIN `meta` AS `Parent` ON
                    `meta`.`ParentID` = `Parent`.`ID` AND
                    `meta`.`Language` = `Parent`.`Language` AND
                    `Parent`.`Module` = 'articles'
            WHERE
                `meta`.`Language` = 'bg'
         AND `articles`.`HomePage` = 1 AND
                `meta`.`Visible` = 1
            
            GROUP BY
                `articles`.`ID`
            ORDER BY
                `meta`.`PostDate` ASC
         LIMIT 0, 3

SELECT
                COUNT(`meta`.`ID`)
            FROM
                `meta`
            WHERE
                `Module` = 'articles' AND
                `Language` = 'bg' AND
                `ParentID` > 9999

SELECT
                `meta`.`Module`,
                `pages`.`MenuLabel`,
                `pages`.`FooterLabel`,
                IF(`Parent`.`URLLabel` = 'index', `meta`.`URLLabel`, CONCAT(`Parent`.`URLLabel`, '/', `meta`.`URLLabel`)) AS `URLLabel`
            FROM
                `meta`
                INNER JOIN `pages` ON
                    `pages`.`ID` = `meta`.`ID` AND
                    `pages`.`Language` = `meta`.`Language`
                LEFT JOIN `meta` AS `Parent` ON
                    `meta`.`ParentID` = `Parent`.`ID` AND
                    `meta`.`Language` = `Parent`.`Language`
            WHERE
                `pages`.`Language` = 'bg' AND
                (`pages`.`MenuLabel` <> '' OR `pages`.`FooterLabel` <> '') AND
                (`meta`.`Module` = 'pages' OR `Parent`.`Module` = 'pages' OR `meta`.`Module` = `Parent`.`Module`)
         AND `meta`.`Visible` = 1
            GROUP BY
                `pages`.`ID`
            ORDER BY
                `meta`.`PostDate` ASC

SELECT
                `Label`,
                `Value`
            FROM
                `labels`
            WHERE
                `Label` IN ('Address','AddressURL','LFollowUs','FacebookURL','TripadvisorURL','Phone','EMail','LFooterInfo','LContactUs','Copyright') AND
                `Language` = 'bg'
             ORDER BY
                `labels`.`Label` ASC
