SELECT *
FROM jos_session
WHERE session_id = 'bn9c1ntkm8f7q1dscsmaf9pld7'
DELETE
FROM jos_session
WHERE ( time < '1283644250' )
SELECT *
FROM jos_session
WHERE session_id = 'bn9c1ntkm8f7q1dscsmaf9pld7'
UPDATE `jos_session`
SET `time`='1283645150',`userid`='0',`usertype`='',`username`='',`gid`='0',`guest`='1',`client_id`='0',`data`='__default|a:134:{s:15:\"session.counter\";i:6;s:19:\"session.timer.start\";i:1283644748;s:18:\"session.timer.last\";i:1283645048;s:17:\"session.timer.now\";i:1283645075;s:22:\"session.client.browser\";s:48:\"CCBot/1.0 (+http://www.commoncrawl.org/bot.html)\";s:8:\"registry\";O:9:\"JRegistry\":3:{s:17:\"_defaultNameSpace\";s:7:\"session\";s:9:\"_registry\";a:1:{s:7:\"session\";a:1:{s:4:\"data\";O:8:\"stdClass\":0:{}}}s:7:\"_errors\";a:0:{}}s:4:\"user\";O:5:\"JUser\":19:{s:2:\"id\";i:0;s:4:\"name\";N;s:8:\"username\";N;s:5:\"email\";N;s:8:\"password\";N;s:14:\"password_clear\";s:0:\"\";s:8:\"usertype\";N;s:5:\"block\";N;s:9:\"sendEmail\";i:0;s:3:\"gid\";i:0;s:12:\"registerDate\";N;s:13:\"lastvisitDate\";N;s:10:\"activation\";N;s:6:\"params\";N;s:3:\"aid\";i:0;s:5:\"guest\";i:1;s:7:\"_params\";O:10:\"JParameter\":7:{s:4:\"_raw\";s:0:\"\";s:4:\"_xml\";N;s:9:\"_elements\";a:0:{}s:12:\"_elementPath\";a:1:{i:0;s:79:\"/home/sites/marshallarts.ie/public_html/libraries/joomla/html/parameter/element\";}s:17:\"_defaultNameSpace\";s:8:\"_default\";s:9:\"_registry\";a:1:{s:8:\"_default\";a:1:{s:4:\"data\";O:8:\"stdClass\":0:{}}}s:7:\"_errors\";a:0:{}}s:9:\"_errorMsg\";N;s:7:\"_errors\";a:0:{}}s:13:\"tpCSSLoadList\";a:1:{s:108:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/css/tpmenu/dropxtd.css\";a:0:{}}s:12:\"tpJSLoadList\";a:6:{s:86:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/javascript/jquery.js\";a:0:{}s:98:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/javascript/jquery.no.conflict.js\";a:0:{}s:119:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/javascript/jquery.lazyload.min.js\";a:0:{}s:106:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/javascript/extra.php\";a:0:{}s:106:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/extensions/tpmenu/javascript/menu.js.php\";a:1:{i:0;a:1:{s:8:\"animated\";s:29:\"Fx.Transitions.Bounce.easeOut\";}}s:97:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/extensions/cufon/javascript.php\";a:1:{i:0;a:8:{s:3:\"cfc\";s:5:\"Vegur\";s:4:\"cfmb\";s:3:\"all\";s:5:\"cfacc\";s:2:\"-1\";s:4:\"cfmf\";s:5:\"Vegur\";s:5:\"cftpp\";s:10:\"Droid Sans\";s:6:\"cftpps\";s:5:\"Vegur\";s:5:\"cftpc\";s:10:\"Droid Sans\";s:6:\"cftpcs\";s:5:\"Vegur\";}}}s:12:\"tp_is_mobile\";b:0;s:12:\"tp_direction\";s:3:\"ltr\";s:34:\"tpparams_globalwidth_templatewidth\";s:4:\"1024\";s:35:\"tpparams_globalwidth_blockleftwidth\";s:3:\"240\";s:36:\"tpparams_globalwidth_blockrightwidth\";s:3:\"240\";s:27:\"tpparams_globalwidth_gutter\";s:2:\"12\";s:40:\"tpparams_customwidth_templatewidthcustom\";s:0:\"\";s:41:\"tpparams_customwidth_blockleftwidthcustom\";s:0:\"\";s:42:\"tpparams_customwidth_blockrightwidthcustom\";s:0:\"\";s:33:\"tpparams_customwidth_guttercustom\";s:0:\"\";s:35:\"tpparams_stylerelated_templatetheme\";s:6:\"bright\";s:45:\"tpparams_stylerelated_notloadmainbodyinitemid\";s:0:\"\";s:39:\"tpparams_stylerelated_backgroundimgpath\";s:17:\"images/bgbody.jpg\";s:37:\"tpparams_stylerelated_backgroundcolor\";s:7:\"#000000\";s:35:\"tpparams_stylerelated_logoplacement\";s:4:\"left\";s:30:\"tpparams_stylerelated_logotext\";s:12:\"Marshallarts\";s:37:\"tpparams_stylerelated_blockheadheight\";s:2:\"99\";s:31:\"tpparams_stylerelated_logowidth\";s:3:\"600\";s:34:\"tpparams_stylerelated_blocktoptype\";s:1:\"0\";s:34:\"tpparams_stylerelated_blockbottype\";s:1:\"0\";s:32:\"tpparams_skeleton_skeletonitemid\";s:0:\"\";s:26:\"tpparams_skeleton_skeleton\";s:9:\"skeleton1\";s:28:\"tpparams_font_primaryfontfam\";s:5:\"arial\";s:30:\"tpparams_font_secondaryfontfam\";s:5:\"arial\";s:29:\"tpparams_font_tertieryfontfam\";s:11:\"lucida-sans\";s:29:\"tpparams_font_primaryfontsize\";s:3:\"big\";s:31:\"tpparams_font_secondaryfontsize\";s:3:\"big\";s:30:\"tpparams_font_tertieryfontsize\";s:8:\"standard\";s:22:\"tpparams_mobile_enable\";s:1:\"1\";s:28:\"tpparams_mobile_enableswitch\";s:1:\"1\";s:20:\"tpparams_mobile_menu\";s:8:\"mainmenu\";s:27:\"tpparams_mobile_menudisplay\";s:5:\"image\";s:28:\"tpparams_mobile_menumaxcount\";s:1:\"9\";s:28:\"tpparams_mobile_tpmobilelist\";s:6:\"iphone\";s:21:\"tpparams_seo_meta_gen\";s:0:\"\";s:23:\"tpparams_seo_google_key\";s:0:\"\";s:22:\"tpparams_seo_yahoo_key\";s:0:\"\";s:20:\"tpparams_seo_msn_key\";s:0:\"\";s:25:\"tpparams_other_ie6checker\";s:1:\"1\";s:30:\"tpparams_other_compresscssfile\";s:1:\"0\";s:22:\"tpparams_other_gzipcss\";s:1:\"1\";s:21:\"tpparams_other_gzipjs\";s:1:\"1\";s:37:\"tpextensions_accordion_moduleposition\";s:11:\"noaccordion\";s:37:\"tpextensions_accordion_defaultdisplay\";s:1:\"1\";s:33:\"tpextensions_accordion_canhideall\";s:1:\"0\";s:30:\"tpextensions_accordion_opacity\";s:1:\"0\";s:28:\"tpextensions_cufon_incontent\";s:5:\"Vegur\";s:32:\"tpextensions_cufon_inmoduleblock\";s:3:\"all\";s:31:\"tpextensions_cufon_inmodulefont\";s:5:\"Vegur\";s:34:\"tpextensions_cufon_inaccordionfont\";s:2:\"-1\";s:33:\"tpextensions_cufon_intpmenuparent\";s:10:\"Droid Sans\";s:36:\"tpextensions_cufon_intpmenuparentsub\";s:5:\"Vegur\";s:32:\"tpextensions_cufon_intpmenuchild\";s:10:\"Droid Sans\";s:35:\"tpextensions_cufon_intpmenuchildsub\";s:5:\"Vegur\";s:29:\"tpextensions_mootabs_position\";s:4:\"none\";s:26:\"tpextensions_mootabs_style\";s:1:\"4\";s:25:\"tpextensions_mootabs_mode\";s:10:\"horizontal\";s:29:\"tpextensions_mootabs_autoplay\";s:1:\"1\";s:29:\"tpextensions_mootabs_interval\";s:4:\"3000\";s:31:\"tpextensions_mootabs_transition\";s:1:\"0\";s:29:\"tpextensions_mootabs_duration\";s:4:\"1000\";s:26:\"tpextensions_mootabs_width\";s:3:\"200\";s:27:\"tpextensions_mootabs_height\";s:3:\"180\";s:33:\"tpextensions_styleswitcher_active\";s:1:\"1\";s:25:\"tpextensions_tpmenu_style\";s:7:\"dropxtd\";s:31:\"tpextensions_tpmenu_columnwidth\";s:3:\"200\";s:24:\"tpextensions_tpmenu_menu\";s:8:\"mainmenu\";s:28:\"tpextensions_tpmenu_animated\";s:1:\"1\";s:29:\"tpextensions_tpmenu_showimage\";s:1:\"1\";s:33:\"tpextensions_tpmenu_imageposition\";s:4:\"left\";s:32:\"tpextensions_tpmenu_showmenutext\";s:1:\"1\";s:33:\"tpextensions_tpmenu_dropcolumnnum\";s:1:\"2\";s:12:\"tpuser_right\";i:6;s:12:\"tpuser_login\";i:0;s:13:\"tpuser_cpanel\";i:0;s:13:\"tpuser_header\";i:0;s:14:\"tpuser_toolbar\";i:0;s:11:\"tpuser_icon\";i:0;s:13:\"tpuser_footer\";i:1;s:11:\"tpuser_menu\";i:0;s:14:\"tpuser_submenu\";i:0;s:13:\"tpuser_status\";i:0;s:12:\"tpuser_title\";i:0;s:18:\"tpuser_beforeright\";i:0;s:11:\"tpuser_left\";i:2;s:10:\"tpuser_top\";i:1;s:12:\"tpuser_user4\";i:1;s:12:\"tpuser_user3\";i:2;s:17:\"tpuser_breadcrumb\";i:1;s:16:\"tpuser_syndicate\";i:1;s:12:\"tpuser_user1\";i:0;s:13:\"tpuser_user22\";i:0;s:13:\"tpuser_user21\";i:0;s:13:\"tpuser_user23\";i:0;s:13:\"tpuser_user24\";i:0;s:12:\"tpuser_user6\";i:0;s:12:\"tpuser_user5\";i:0;s:13:\"tpuser_extra1\";i:0;s:13:\"tpuser_banner\";i:0;s:13:\"tpuser_user11\";i:0;s:13:\"tpuser_user12\";i:0;s:13:\"tpuser_user14\";i:0;s:13:\"tpuser_user13\";i:0;s:12:\"tpuser_user2\";i:0;s:14:\"tpuser_advert3\";i:0;s:17:\"tpuser_beforeleft\";i:0;s:16:\"tpuser_afterleft\";i:0;s:17:\"tpuser_afterright\";i:0;s:14:\"tpuser_advert1\";i:0;s:14:\"tpuser_advert2\";i:0;s:14:\"tpuser_advert4\";i:0;s:12:\"tpuser_user8\";i:0;s:16:\"tpuser_mobiletop\";i:0;s:19:\"tpuser_mobilebottom\";i:0;s:19:\"tpuser_bannermobile\";i:0;s:13:\"tpuser_extra2\";i:0;s:13:\"tpuser_extra3\";i:0;s:13:\"tpuser_extra4\";i:0;s:13:\"tpuser_extra5\";i:0;s:17:\"tpuser_user_agent\";s:48:\"CCBot/1.0 (+http://www.commoncrawl.org/bot.html)\";s:16:\"tp_skeleton_used\";a:2:{i:0;s:7:\"general\";i:1;s:9:\"skeleton1\";}s:14:\"_tp_CSSForLoad\";a:19:{i:0;a:2:{i:0;s:79:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/reset.css\";i:1;s:3:\"all\";}i:1;a:2:{i:0;s:81:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/general.css\";i:1;s:3:\"all\";}i:2;a:2:{i:0;s:80:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/joomla.css\";i:1;s:3:\"all\";}i:3;a:2:{i:0;s:82:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/template.css\";i:1;s:3:\"all\";}i:4;a:2:{i:0;s:80:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/module.css\";i:1;s:3:\"all\";}i:5;a:2:{i:0;s:77:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/ie6.css\";i:1;s:6:\"msie 6\";}i:6;a:2:{i:0;s:77:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/ie7.css\";i:1;s:6:\"msie 7\";}i:7;a:2:{i:0;s:77:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/ie8.css\";i:1;s:6:\"msie 8\";}i:8;a:2:{i:0;s:79:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/opera.css\";i:1;s:5:\"opera\";}i:9;a:2:{i:0;s:80:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/webkit.css\";i:1;s:6:\"webkit\";}i:10;a:2:{i:0;s:95:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/style.php\";i:1;s:3:\"all\";}i:11;a:2:{i:0;s:86:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/theme/bright.css\";i:1;s:3:\"all\";}i:12;a:2:{i:0;s:98:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontfamily/primary/arial.css\";i:1;s:3:\"all\";}i:13;a:2:{i:0;s:100:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontfamily/secondary/arial.css\";i:1;s:3:\"all\";}i:14;a:2:{i:0;s:105:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontfamily/tertiery/lucida-sans.css\";i:1;s:3:\"all\";}i:15;a:2:{i:0;s:94:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontsize/primary/big.css\";i:1;s:3:\"all\";}i:16;a:2:{i:0;s:96:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontsize/secondary/big.css\";i:1;s:3:\"all\";}i:17;a:2:{i:0;s:100:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/css/fontsize/tertiery/standard.css\";i:1;s:3:\"all\";}i:18;a:3:{i:0;s:108:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/css/tpmenu/dropxtd.css\";i:1;s:3:\"all\";i:2;N;}}s:13:\"_tp_JSForLoad\";a:7:{i:0;a:1:{i:0;s:88:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/javascript/template.js\";}i:1;a:3:{i:0;s:86:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/javascript/jquery.js\";i:1;s:3:\"all\";i:2;N;}i:2;a:3:{i:0;s:98:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/javascript/jquery.no.conflict.js\";i:1;s:3:\"all\";i:2;N;}i:3;a:3:{i:0;s:119:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/javascript/jquery.lazyload.min.js\";i:1;s:3:\"all\";i:2;N;}i:4;a:3:{i:0;s:106:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/skeletons/skeleton1/javascript/extra.php\";i:1;s:3:\"all\";i:2;N;}i:5;a:3:{i:0;s:106:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/extensions/tpmenu/javascript/menu.js.php\";i:1;s:3:\"all\";i:2;a:1:{s:8:\"animated\";s:29:\"Fx.Transitions.Bounce.easeOut\";}}i:6;a:3:{i:0;s:97:\"/home/sites/marshallarts.ie/public_html/templates/galleria_plazza/extensions/cufon/javascript.php\";i:1;s:3:\"all\";i:2;a:8:{s:3:\"cfc\";s:5:\"Vegur\";s:4:\"cfmb\";s:3:\"all\";s:5:\"cfacc\";s:2:\"-1\";s:4:\"cfmf\";s:5:\"Vegur\";s:5:\"cftpp\";s:10:\"Droid Sans\";s:6:\"cftpps\";s:5:\"Vegur\";s:5:\"cftpc\";s:10:\"Droid Sans\";s:6:\"cftpcs\";s:5:\"Vegur\";}}}s:13:\"session.token\";s:32:\"90c7829e8dfe10eebb859da80e388e59\";s:16:\"tp_currentitemid\";s:3:\"126\";}'
WHERE session_id='bn9c1ntkm8f7q1dscsmaf9pld7'
SELECT *
FROM jos_components
WHERE parent = 0
SELECT folder AS type, element AS name, params
FROM jos_plugins
WHERE published >= 1
AND access <= 0
ORDER BY ordering
SELECT m.*, c.`option` AS component
FROM jos_menu AS m
LEFT JOIN jos_components AS c
ON m.componentid = c.id
WHERE m.published = 1
ORDER BY m.sublevel, m.parent, m.ordering
SELECT published
FROM jos_plugins
WHERE element = 'jceembed' OR element = 'mediaobject'
SELECT template
FROM jos_templates_menu
WHERE client_id = 0
AND (menuid = 0 OR menuid = 1)
ORDER BY menuid DESC
LIMIT 0, 1
SELECT a.id, a.title, a.alias, a.title_alias, a.introtext, a.fulltext, a.sectionid, a.state, a.catid, a.created, a.created_by, a.created_by_alias, a.modified, a.modified_by, a.checked_out, a.checked_out_time, a.publish_up, a.publish_down, a.images, a.attribs, a.urls, a.metakey, a.metadesc, a.access, CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(':', a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug, CHAR_LENGTH( a.`fulltext` ) AS readmore, u.name AS author, u.usertype, g.name AS groups, u.email AS author_email, cc.title AS category, s.title AS section, s.ordering AS s_ordering, cc.ordering AS cc_ordering, a.ordering AS a_ordering, f.ordering AS f_ordering
FROM jos_content AS a
INNER JOIN jos_content_frontpage AS f
ON f.content_id = a.id
LEFT JOIN jos_categories AS cc
ON cc.id = a.catid
LEFT JOIN jos_sections AS s
ON s.id = a.sectionid
LEFT JOIN jos_users AS u
ON u.id = a.created_by
LEFT JOIN jos_groups AS g
ON a.access = g.id
WHERE 1
AND a.access <= 0
AND a.state = 1
AND (( cc.published = 1
AND s.published = 1 ) OR ( a.catid = 0
AND a.sectionid = 0 ) )
AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-09-05 00:05:51' )
AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-09-05 00:05:51' )
ORDER BY f.ordering
LIMIT 0, 8
SELECT a.id, a.title, a.alias, a.title_alias, a.introtext, a.fulltext, a.sectionid, a.state, a.catid, a.created, a.created_by, a.created_by_alias, a.modified, a.modified_by, a.checked_out, a.checked_out_time, a.publish_up, a.publish_down, a.images, a.attribs, a.urls, a.metakey, a.metadesc, a.access, CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(':', a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug, CHAR_LENGTH( a.`fulltext` ) AS readmore, u.name AS author, u.usertype, g.name AS groups, u.email AS author_email, cc.title AS category, s.title AS section, s.ordering AS s_ordering, cc.ordering AS cc_ordering, a.ordering AS a_ordering, f.ordering AS f_ordering
FROM jos_content AS a
INNER JOIN jos_content_frontpage AS f
ON f.content_id = a.id
LEFT JOIN jos_categories AS cc
ON cc.id = a.catid
LEFT JOIN jos_sections AS s
ON s.id = a.sectionid
LEFT JOIN jos_users AS u
ON u.id = a.created_by
LEFT JOIN jos_groups AS g
ON a.access = g.id
WHERE 1
AND a.access <= 0
AND a.state = 1
AND (( cc.published = 1
AND s.published = 1 ) OR ( a.catid = 0
AND a.sectionid = 0 ) )
AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-09-05 00:05:51' )
AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-09-05 00:05:51' )
ORDER BY f.ordering
SELECT DISTINCT position
FROM jos_modules
SELECT id, title, module, position, content, showtitle, control, params
FROM jos_modules AS m
LEFT JOIN jos_modules_menu AS mm
ON mm.moduleid = m.id
WHERE m.published = 1
AND m.access <= 0
AND m.client_id = 0
AND ( mm.menuid = 1 OR mm.menuid = 0 )
ORDER BY position, ordering
SELECT m.*, sum(case when p.published=1 then 1 else 0 end) AS cnt
FROM jos_menu AS m
LEFT JOIN jos_menu AS p
ON p.parent = m.id
WHERE m.menutype='mainmenu'
AND m.published='1'
AND m.access <= '0'
GROUP BY m.id
ORDER BY m.parent, m.ordering
SELECT m.*
FROM jos_menu AS m
WHERE menutype='mainmenu'
AND m.published='1'
SELECT DISTINCT position
FROM jos_modules
SELECT (SUM(vr.votesum)/SUM(vr.votecount)) AS vote,
SUM(vr.votesum) AS votesum,
SUM(vr.votecount) AS votecount,
b.title AS cattitle,
a.*
FROM jos_tpwebgallery_items AS a
INNER JOIN jos_tpwebgallery_categories AS b
ON a.catid=b.id
AND b.published=1
LEFT JOIN jos_tpwebgallery_vote_result AS vr
ON vr.itemid=a.id
LEFT JOIN jos_tpwebgallery_votes AS v
ON v.id=vr.voteid
AND v.published=1
WHERE a.published=1
AND a.approved=1
AND a.deleted=0
GROUP BY a.id
ORDER BY vote ASC
LIMIT 5
SELECT COUNT(*)
FROM jos_tpwebgallery_votes
WHERE published=1
SELECT SUM(votecount) AS vc, SUM(votesum) AS vs
FROM jos_tpwebgallery_vote_result
WHERE itemid=13
SELECT COUNT(*)
FROM jos_tpwebgallery_votes
WHERE published=1
SELECT SUM(votecount) AS vc, SUM(votesum) AS vs
FROM jos_tpwebgallery_vote_result
WHERE itemid=15
SELECT COUNT(*)
FROM jos_tpwebgallery_votes
WHERE published=1
SELECT SUM(votecount) AS vc, SUM(votesum) AS vs
FROM jos_tpwebgallery_vote_result
WHERE itemid=16
SELECT COUNT(*)
FROM jos_tpwebgallery_votes
WHERE published=1
SELECT SUM(votecount) AS vc, SUM(votesum) AS vs
FROM jos_tpwebgallery_vote_result
WHERE itemid=20
SELECT COUNT(*)
FROM jos_tpwebgallery_votes
WHERE published=1
SELECT SUM(votecount) AS vc, SUM(votesum) AS vs
FROM jos_tpwebgallery_vote_result
WHERE itemid=22
SELECT DISTINCT(a.userid), count(a.id) AS items, b.lastvisitDate
FROM jos_tpwebgallery_items AS a
INNER JOIN jos_users AS b
ON a.userid=b.id
WHERE a.published=1
AND a.approved=1
AND a.deleted=0
AND b.block=0
GROUP BY a.userid
ORDER BY a.id DESC
LIMIT 5
SELECT a.*, COUNT(c.id) AS countitems
FROM jos_tpwebgallery_tags AS a
INNER JOIN jos_tpwebgallery_item_tag AS b
ON a.id=b.tagid
INNER JOIN jos_tpwebgallery_items AS c
ON c.id=b.itemid
AND c.published=1
AND c.approved=1
AND c.deleted=0
WHERE a.published=1
GROUP BY a.id
ORDER BY a.title ASC
LIMIT 5
SELECT a.*, CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(":", a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug
FROM jos_content AS a
INNER JOIN jos_categories AS cc
ON cc.id = a.catid
INNER JOIN jos_sections AS s
ON s.id = a.sectionid
WHERE a.state = 1
AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-09-05 00:05:51' )
AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-09-05 00:05:51' )
AND s.id > 0
AND a.access <= 0
AND cc.access <= 0
AND s.access <= 0
AND s.published = 1
AND cc.published = 1
ORDER BY a.created DESC
LIMIT 0, 5
SELECT a.*, CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(":", a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug
FROM jos_content AS a
LEFT JOIN jos_content_frontpage AS f
ON f.content_id = a.id
INNER JOIN jos_categories AS cc
ON cc.id = a.catid
INNER JOIN jos_sections AS s
ON s.id = a.sectionid
WHERE ( a.state = 1
AND s.id > 0 )
AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-09-05 00:05:51' )
AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-09-05 00:05:51' )
AND a.access <= 0
AND cc.access <= 0
AND s.access <= 0
AND s.published = 1
AND cc.published = 1
ORDER BY a.hits DESC
LIMIT 0, 5
SELECT *
FROM jos_banner
WHERE showBanner = 1
AND (imptotal = 0 OR impmade < imptotal)
AND catid = 14
ORDER BY sticky DESC, ordering
LIMIT 0, 4
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 3
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 4
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 5
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 6
SELECT id, title, CASE WHEN CHAR_LENGTH(alias) THEN CONCAT_WS(':', id, alias) ELSE id END AS slug
FROM jos_polls
WHERE id = 14
AND published = 1
SELECT id, text
FROM jos_poll_data
WHERE pollid = 14
AND text <> ""
ORDER BY id
SELECT *
FROM jos_banner
WHERE showBanner = 1
AND (imptotal = 0 OR impmade < imptotal)
AND cid = 1
AND catid = 35
ORDER BY sticky DESC, ordering
LIMIT 0, 10
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 19
SELECT *
FROM jos_banner
WHERE showBanner = 1
AND (imptotal = 0 OR impmade < imptotal)
AND cid = 1
AND catid = 35
ORDER BY sticky DESC, ordering
LIMIT 0, 1
UPDATE jos_banner
SET impmade = impmade + 1
WHERE bid = 19