Index: branches/Ver2.0/xpressme_integration_kit/include/xpress_render.php
===================================================================
--- branches/Ver2.0/xpressme_integration_kit/include/xpress_render.php	(revision 266)
+++ branches/Ver2.0/xpressme_integration_kit/include/xpress_render.php	(revision 278)
@@ -5,6 +5,11 @@
 {
 	global $xpress_config;
+	
+	$pattern = "<body[^>]*?>(.*)<\/body>";
+	$body_cut = preg_replace("/".$pattern."/s" , '' , $contents);
+
+
 	$pattern = "<head[^>]*?>(.*)<\/head>";
-	preg_match("/".$pattern."/s",  $contents, $head_matches);
+	preg_match("/".$pattern."/s",  $body_cut, $head_matches);
 	$head_str = $head_matches[1];
 	
@@ -208,7 +213,7 @@
 	$xpress_data['left_post_link'] = $GLOBALS['left_arrow_post_link'];
 	$xpress_data['right_post_link'] = $GLOBALS['right_arrow_post_link'];
-	$xpress_data['left_posts_link'] =  str_replace('&laquo;','',xpress_left_arrow_posts_link(false));
-	$xpress_data['right_posts_link'] = str_replace('&raquo;','',xpress_right_arrow_posts_link(false));
-	$xpress_data['now_user_level'] = xpress_now_user_level(false);
+	$xpress_data['left_posts_link'] =  str_replace('&laquo;','',xpress_left_arrow_posts_link('echo=0'));
+	$xpress_data['right_posts_link'] = str_replace('&raquo;','',xpress_right_arrow_posts_link('echo=0'));
+	$xpress_data['now_user_level'] = xpress_now_user_level('echo=0');
 
 	$xoopsTpl->assign('xpress', $xpress_data);
