diff --git a/e107_plugins/content/content.php b/e107_plugins/content/content.php index 82589764f..376bf0938 100644 --- a/e107_plugins/content/content.php +++ b/e107_plugins/content/content.php @@ -12,8 +12,8 @@ | GNU General Public License (http://gnu.org). | | $Source: /cvs_backup/e107_0.8/e107_plugins/content/content.php,v $ -| $Revision: 1.15 $ -| $Date: 2007-04-17 21:06:06 $ +| $Revision: 1.16 $ +| $Date: 2007-04-18 20:31:16 $ | $Author: lisa_ $ +---------------------------------------------------------------+ */ @@ -745,7 +745,7 @@ function show_content_cat($mode=""){ $textparent = $aa->getCrumbPage("cat", $array, $mainparent).$textparent; if( varsettrue($textparent) ){ $ns -> tablerender($caption, $textparent); } - if($resultitem = $sql -> db_Select($plugintable, "*", $qry )){ + if($resultitem = $sql -> db_Select($plugintable, "content_heading, content_rate, content_comment", $qry )){ $row = $sql -> db_Fetch(); if($row['content_comment']){ $cachestr = "comment.$plugintable.$qs[1]"; diff --git a/e107_plugins/content/e_list.php b/e107_plugins/content/e_list.php index b5463cf86..67cb14246 100644 --- a/e107_plugins/content/e_list.php +++ b/e107_plugins/content/e_list.php @@ -21,7 +21,7 @@ if (!defined('e107_INIT')) { exit; } //get main parent types $sqlm = new db; - if(!$mainparents = $sqlm -> db_Select("pcontent", "*", "content_class REGEXP '".e_CLASS_REGEXP."' AND content_parent = '0' ".$datequery." ".$headingquery." ORDER BY content_heading")){ + if(!$mainparents = $sqlm -> db_Select("pcontent", "content_id, content_heading", "content_class REGEXP '".e_CLASS_REGEXP."' AND content_parent = '0' ".$datequery." ".$headingquery." ORDER BY content_heading")){ $LIST_DATA = "no valid content category"; }else{ while($rowm = $sqlm -> db_Fetch()){ @@ -57,7 +57,7 @@ if (!defined('e107_INIT')) { exit; } //get recent content for each main parent $sqli = new db; - if(!$resultitem = $sqli -> db_Select("pcontent", "*", $qry)){ + if(!$resultitem = $sqli -> db_Select("pcontent", "content_id, content_heading, content_parent, content_datestamp, content_icon, content_author", $qry)){ $LIST_DATA = "no items in ".$rowm['content_heading']; }else{ $LIST_DISPLAYSTYLE = ($arr[2] ? "" : "none"); diff --git a/e107_plugins/content/handlers/content_class.php b/e107_plugins/content/handlers/content_class.php index b172b388a..ae31b0ad9 100644 --- a/e107_plugins/content/handlers/content_class.php +++ b/e107_plugins/content/handlers/content_class.php @@ -12,8 +12,8 @@ | GNU General Public License (http://gnu.org). | | $Source: /cvs_backup/e107_0.8/e107_plugins/content/handlers/content_class.php,v $ -| $Revision: 1.19 $ -| $Date: 2007-04-17 21:06:06 $ +| $Revision: 1.20 $ +| $Date: 2007-04-18 20:31:17 $ | $Author: lisa_ $ +---------------------------------------------------------------+ */ @@ -1487,7 +1487,7 @@ class content{ $data .= " }\n"; $data .= " \$checkid = substr(\$checkid,0,-3);\n"; $data .= " if(!is_object(\$sql)){ \$sql = new db; }\n"; - $data .= " if(\$sql -> db_Select(\$plugintable, \"*\", \" \".\$checkid.\" ORDER BY SUBSTRING_INDEX(content_order, '.', 1)+0 \")){\n"; + $data .= " if(\$sql -> db_Select(\$plugintable, \"content_id, content_heading, content_icon\", \" \".\$checkid.\" ORDER BY SUBSTRING_INDEX(content_order, '.', 1)+0 \")){\n"; $data .= " \$CMT_CATEGORY .= \$tp->parseTemplate(\$CONTENT_MENU_CATEGORY_START,TRUE,\$content_shortcodes);\n"; $data .= " while(\$row = \$sql -> db_Fetch()){\n"; $data .= " \$CMT_CATEGORY .= \$tp->parseTemplate(\$CONTENT_MENU_CATEGORY_TABLE,TRUE,\$content_shortcodes);\n"; @@ -1504,7 +1504,7 @@ class content{ $data .= " \$validparent = implode(\",\", array_keys(\$array));\n"; $data .= " \$qry = \" content_parent REGEXP '\".\$aa -> CONTENTREGEXP(\$validparent).\"' \";\n"; $data .= "\n"; - $data .= " if(\$resultitem = \$sql -> db_Select(\$plugintable, \"*\", \"content_refer !='sa' AND \".\$qry.\" \".\$datequery.\" AND content_class REGEXP '\".e_CLASS_REGEXP.\"' ORDER BY content_datestamp DESC LIMIT 0,\".\$content_pref[\"content_menu_recent_number\"] )){\n"; + $data .= " if(\$resultitem = \$sql -> db_Select(\$plugintable, \"content_id, content_heading, content_subheading, content_author, content_icon, content_datestamp\", \"content_refer !='sa' AND \".\$qry.\" \".\$datequery.\" AND content_class REGEXP '\".e_CLASS_REGEXP.\"' ORDER BY content_datestamp DESC LIMIT 0,\".\$content_pref[\"content_menu_recent_number\"] )){\n"; $data .= "\n"; $data .= " \$CMT_RECENT .= \$tp->parseTemplate(\$CONTENT_MENU_RECENT_START,TRUE,\$content_shortcodes);\n"; $data .= " while(\$row = \$sql -> db_Fetch()){\n"; diff --git a/e107_plugins/content/handlers/content_form_class.php b/e107_plugins/content/handlers/content_form_class.php index 1fccb9c26..754d6e0de 100644 --- a/e107_plugins/content/handlers/content_form_class.php +++ b/e107_plugins/content/handlers/content_form_class.php @@ -12,8 +12,8 @@ | GNU General Public License (http://gnu.org). | | $Source: /cvs_backup/e107_0.8/e107_plugins/content/handlers/content_form_class.php,v $ -| $Revision: 1.13 $ -| $Date: 2007-04-17 21:06:06 $ +| $Revision: 1.14 $ +| $Date: 2007-04-18 20:31:17 $ | $Author: lisa_ $ +---------------------------------------------------------------+ */ @@ -248,7 +248,7 @@ class contentform{ //if inherit is used in the manager, we need to get the preferences from the core plugin table default preferences //and use those preferences in the permissions check. if( varsettrue($manager_pref['content_manager_inherit']) ){ - $sql -> db_Select("core", "*", "e107_name='$plugintable' "); + $sql -> db_Select("core", "e107_value", "e107_name='$plugintable' "); $row = $sql -> db_Fetch(); $manager_pref = $eArrayStorage->ReadArray($row['e107_value']); } @@ -270,7 +270,7 @@ class contentform{ //if inherit is used in the manager, we need to get the preferences from the core plugin table default preferences //and use those preferences in the permissions check. if( varsettrue($manager_pref['content_manager_inherit']) ){ - $sql -> db_Select("core", "*", "e107_name='$plugintable' "); + $sql -> db_Select("core", "e107_value", "e107_name='$plugintable' "); $row = $sql -> db_Fetch(); $manager_pref = $eArrayStorage->ReadArray($row['e107_value']); } @@ -889,7 +889,7 @@ class contentform{ //if inherit is used in the manager, we need to get the preferences from the core plugin table default preferences //and use those preferences in the permissions check. if( varsettrue($curpref['content_manager_inherit']) ){ - $sql2 -> db_Select("core", "*", "e107_name='$plugintable' "); + $sql2 -> db_Select("core", "e107_value", "e107_name='$plugintable' "); $row2 = $sql2 -> db_Fetch(); $curpref = $eArrayStorage->ReadArray($row2['e107_value']); } @@ -1018,7 +1018,7 @@ class contentform{ //if inherit is used in the manager, we need to get the preferences from the core plugin table default preferences //and use those preferences in the permissions check. if( varsettrue($content_pref['content_manager_inherit']) ){ - $sql -> db_Select("core", "*", "e107_name='$plugintable' "); + $sql -> db_Select("core", "e107_value", "e107_name='$plugintable' "); $row = $sql -> db_Fetch(); $content_pref = $eArrayStorage->ReadArray($row['e107_value']); } @@ -1078,7 +1078,7 @@ class contentform{ if(!is_object($sql)){ $sql = new db; } foreach($array as $catid){ - if(!$category_total = $sql -> db_Select($plugintable, "*", "content_id='".intval($catid)."' ")){ + if(!$category_total = $sql -> db_Select($plugintable, "content_id, content_heading, content_subheading, content_parent, content_icon, content_author", "content_id='".intval($catid)."' ")){ $text .= "