[CS-Project-svn_notify] SF.net SVN: cs-project:[977] trunk/1.2/includes
Brought to you by:
crazedsanity
From: <cra...@us...> - 2009-08-18 14:20:01
|
Revision: 977 http://cs-project.svn.sourceforge.net/cs-project/?rev=977&view=rev Author: crazedsanity Date: 2009-08-18 14:19:54 +0000 (Tue, 18 Aug 2009) Log Message: ----------- Fix problem with tabs & doing pass-by-reference on "overloaded classes". Modified Paths: -------------- trunk/1.2/includes/content.inc trunk/1.2/includes/login.inc Modified: trunk/1.2/includes/content.inc =================================================================== --- trunk/1.2/includes/content.inc 2009-08-18 14:17:50 UTC (rev 976) +++ trunk/1.2/includes/content.inc 2009-08-18 14:19:54 UTC (rev 977) @@ -13,7 +13,7 @@ $db = new cs_phpDB; $db->connect(get_config_db_params()); -$page->db = &$db; +$page->db = $db; $page->session = new Session($page->db); @@ -93,7 +93,7 @@ //check for old misspellings, and fix them. $defaultModule = "project"; } - conditional_header("/content/$defaultModule"); + conditional_header("/content/". $defaultModule); exit; } @@ -132,7 +132,7 @@ 'tags' => "Tags", ); -$tabObj = new cs_tabs($page); +$tabObj = new cs_tabs(); foreach($tabNames as $moduleName=>$name) { $tabUrl = "/content/". $moduleName; @@ -142,6 +142,7 @@ $tabObj->add_tab($name, $tabUrl); } + if($user->is_admin()) { $name = "Admin"; $tabObj->add_tab($name, "/content/settings/admin"); @@ -149,7 +150,8 @@ $tabObj->select_tab($name); } } -$tabObj->display_tabs(); +$page->rip_all_block_rows('tabs'); +$page->add_template_var('tabs', $tabObj->display_tabs($page->templateRows)); Modified: trunk/1.2/includes/login.inc =================================================================== --- trunk/1.2/includes/login.inc 2009-08-18 14:17:50 UTC (rev 976) +++ trunk/1.2/includes/login.inc 2009-08-18 14:19:54 UTC (rev 977) @@ -13,7 +13,7 @@ $db = new cs_phpDB; $db->connect(get_config_db_params()); -$page->db = &$db; +$page->db = $db; $page->add_template_var('cs-project_version', VERSION_STRING); $page->add_template_var('MAINTABLE_EXTRA', 'align="center"'); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |