// // //
//

 -2018_4105
20 20180
 -2018_4106
20 20180
 -2018_4104
20 20180
 -2018_4103
20 20180
 #6
18 20180
 #5
18 20180
 #4
18 20180
 #3
18 20180
 #2
18 20180
 #1
18 20180
 #6
18 20180
 #5
18 20180
 #4
18 20180
 #3
18 20180
 #2
18 20180
 #1
18 20180
 #6
18 20180
 #5
18 20180
 #4
18 20180
 #3
18 20180
 #2
18 20180
 #1
18 20180
 #6
18 20180
 #5
18 20180
: 0.3416 .
: 47
SET NAMES cp1251

SELECT * FROM cms_menu ORDER BY id ASC

SELECT id, title, link, config, internal, published, version, system FROM cms_components

SELECT p.id, p.plugin, p.config, e.event FROM cms_plugins p, cms_event_hooks e WHERE p.published = 1 AND e.plugin_id = p.id

SELECT id FROM cms_user_groups WHERE alias = 'guest'

DELETE FROM cms_online WHERE lastdate <= DATE_SUB(NOW(), INTERVAL 3 MINUTE)

SELECT id as getfield FROM cms_online WHERE sess_id = 'lhltbo6290peb1ilqsk03lrci4' AND ip = '54.224.17.157' LIMIT 1

INSERT INTO cms_online (ip, sess_id, lastdate, user_id, agent, viewurl) VALUES ('54.224.17.157', 'lhltbo6290peb1ilqsk03lrci4', NOW(), '0', 'CCBot/2.0 (http://commoncrawl.org/faq/)', '/photos/latest.html')

SELECT id FROM cms_stats WHERE (ip = '54.224.17.157' AND page = '/photos/latest.html')

INSERT INTO cms_stats (ip, logdate, page, agent, refer) VALUES ('54.224.17.157', NOW(), '/photos/latest.html', 'CCBot/2.0 (http://commoncrawl.org/faq/)', '')

SELECT NSLeft, NSRight FROM cms_menu WHERE id = '42'

SELECT id, title, link, linktype
                           FROM cms_menu
                           WHERE NSLeft <= 37 AND NSRight >= 38 AND parent_id > 0
                           ORDER BY NSLeft

SELECT id, title FROM cms_photo_albums WHERE parent_id=0 AND NSDiffer='' ORDER BY id ASC LIMIT 1

SELECT f.*, f.pubdate as fpubdate, a.id as album_id, a.title as album
			FROM cms_photo_files f
			LEFT JOIN cms_photo_albums a ON a.id = f.album_id
			WHERE f.published = 1
			ORDER BY pubdate DESC
			LIMIT 24

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4106' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4107' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4105' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4104' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4103' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4102' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4101' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4100' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4099' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4098' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4097' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4096' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4095' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4094' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4093' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4092' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4091' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4090' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4089' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4088' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4087' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4086' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4085' AND published = 1

SELECT id FROM cms_comments WHERE target = 'photo' AND target_id = '4084' AND published = 1

SELECT m.access_list
            FROM cms_modules m, cms_modules_bind mb
            WHERE mb.position = 'top' AND
                  m.published = 1 AND
                  m.id = mb.module_id AND
                  (mb.menu_id = '42' OR mb.menu_id = 0)

SELECT m.access_list
            FROM cms_modules m, cms_modules_bind mb
            WHERE mb.position = 'sidebar' AND
                  m.published = 1 AND
                  m.id = mb.module_id AND
                  (mb.menu_id = '42' OR mb.menu_id = 0)

SELECT *, m.id as mid, m.template as tpl
            FROM cms_modules m, cms_modules_bind mb
            WHERE (mb.position = 'topmenu') AND
                  m.published = 1 AND
                  m.id = mb.module_id AND
                  (mb.menu_id = '42' OR mb.menu_id = 0)
                  
            ORDER BY m.ordering ASC

SELECT NSLeft, NSRight, NSLevel FROM cms_menu WHERE id = '42' ORDER BY id ASC LIMIT 1

SELECT id as getfield FROM cms_menu WHERE parent_id=0 LIMIT 1

SELECT * FROM cms_menu WHERE id = 1 AND NSDiffer = ''

SELECT * FROM cms_menu WHERE NSLeft > 1 AND NSRight < 66 AND NSDiffer = '' ORDER BY NSLeft,ordering

SELECT *, m.id as mid, m.template as tpl
            FROM cms_modules m, cms_modules_bind mb
            WHERE (mb.position = 'maintop') AND
                  m.published = 1 AND
                  m.id = mb.module_id AND
                  (mb.menu_id = '42' OR mb.menu_id = 0)
                  
            ORDER BY m.ordering ASC

SELECT *, m.id as mid, m.template as tpl
            FROM cms_modules m, cms_modules_bind mb
            WHERE (mb.position = 'mainbottom') AND
                  m.published = 1 AND
                  m.id = mb.module_id AND
                  (mb.menu_id = '42' OR mb.menu_id = 0)
                  
            ORDER BY m.ordering ASC