------------------------------------------------------------
revno: 1137
committer: Roger Martin <[email protected]>
branch nick: aikiframework
timestamp: Mon 2012-03-12 06:54:54 +0100
message:
  aiki layout corrected
modified:
  index.php


--
lp:aikiframework
https://code.launchpad.net/~aikiframework-devel/aikiframework/trunk

Your team Aiki Framework Developers is subscribed to branch lp:aikiframework.
To unsubscribe from this branch go to 
https://code.launchpad.net/~aikiframework-devel/aikiframework/trunk/+edit-subscription
=== modified file 'index.php'
--- index.php	2012-02-19 20:19:24 +0000
+++ index.php	2012-03-12 05:54:54 +0000
@@ -35,6 +35,7 @@
  */
 require_once("bootstrap.php");
 config_error_reporting();
+error_reporting(E_ALL); 
 
 /**
  * cache_file have tree result:
@@ -52,25 +53,20 @@
 	// Content is generated by old aiki engine
 	
 	require_once("libs/Engine_aiki.php");
-	$layout = new Engine_Aiki();
-	$layout->layout();	
+	$engine = new Engine_Aiki();
+	$engine->render();
 	
-	if (isset($global_widget) or isset($_REQUEST['noheaders'])) {
-		$noheaders  = true;
-	} else {
-		$noheaders  = false;	
-	}
+	$noheaders =  isset($_REQUEST['noheaders']) ? true: false;
 
-	if ( $noheaders || $layout->widget_custom_output) {
-		$html_output = $aiki->Output->custom_output($layout->html_output);
+	if ( $noheaders || $engine->widget_custom_output) {
+		$html_output = $aiki->Output->custom_output($engine);		
 	} else {   
-		$html_output = $aiki->Output->header($layout->widgets_css, $layout->head_output);		
-		$layout->html_output = str_replace(
-				'[page_title]', 
-				$aiki->Output->get_title(),
-				$layout->html_output);		
-		$html_output .= $aiki->Output->body($layout->html_output);
+  
+		$html_output  = $aiki->Output->header($engine->target['css'], $engine->target['header']);
+		$html_output .= $aiki->Output->body($engine->target['body']);
 		$html_output .= $aiki->Output->end();
+									
+		$html_output = str_replace(	'[page_title]', $aiki->Output->get_title(),	$html_output);
 	} 
 
 	$html_output = $aiki->languages->L10n($html_output);
@@ -80,7 +76,7 @@
     include "$AIKI_ROOT_DIR/libs/Engine_$engineType.php";
     $engineClass= "Engine_" . $engineType;       
     $engine = new $engineClass();
-    $html_output = $engine->layout($aiki->site->engine_parameters());    
+    $html_output = $engine->render($aiki->site->engine_parameters());    
 	
 } else {
 	// engine is no valid

_______________________________________________
Mailing list: https://launchpad.net/~aikiframework-devel
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~aikiframework-devel
More help   : https://help.launchpad.net/ListHelp

Reply via email to