Index: trunk/include/xpress_render.php
===================================================================
--- trunk/include/xpress_render.php	(revision 23)
+++ trunk/include/xpress_render.php	(revision 26)
@@ -35,10 +35,36 @@
 }
 
+// get sidebar rendaring 
+function get_sidebar_rander($name = null)
+{
+	$templates = array();
+	if ( isset($name) )
+		$templates[] = "sidebar-{$name}.php";
+
+	$templates[] = "sidebar.php";
+
+	$link= locate_template($templates, false);
+	if ('' == $link)
+		$link =  get_theme_root() . '/default/sidebar.php';
+
+	ob_start();
+		require($link);
+		$sidebar = ob_get_contents();
+	ob_end_clean();
+	return $sidebar;
+}
+
 // < body > tag is pulled out from the header of html contents. 
 function get_body($contents)
 {
+	$xpess_config = new XPressME_Class();
 	$pattern = "<body[^>]*?>(.*)<\/body>";
 	preg_match("/".$pattern."/s",  $contents, $body_matches);
 	$body = $body_matches[1];
+
+	if (!$xpess_config->is_theme_sidebar_disp){
+		$side_panel = get_sidebar_rander();
+			$body = str_replace($side_panel,'',$body);
+	}
 	return $body;
 }
