Browse Source

Merge with 368afdadfa4c205584318362f5988880e7e2371c

Ivan Tcholakov 15 years ago
parent
commit
7b1f941c5c
3 changed files with 12 additions and 4 deletions
  1. 2 2
      main/inc/lib/html2pdf/html2pdf.class.php
  2. 5 1
      main/wiki/index.php
  3. 5 1
      main/wiki/wiki.inc.php

+ 2 - 2
main/inc/lib/html2pdf/html2pdf.class.php

@@ -2823,13 +2823,13 @@ if (!defined('__CLASS_HTML2PDF__'))
 				if ($this->maxH) $this->o_BR(array());
 				$this->o_BR(array());
 			}
-			
+						
 			$this->style->save();
 			$this->style->analyse('p', $param);
 			$this->style->setPosition($this->pdf->x, $this->pdf->y);
 			$this->style->FontSet();
 			
-			if ($this->style->value['text-indent']>0) $this->pdf->x+= $this->style->value['text-indent'];
+			if ($this->style->value['text-indent']>0) $this->pdf->x+= $this->style->value['text-indent'];	
 			
 			return true;
 		}

+ 5 - 1
main/wiki/index.php

@@ -1252,7 +1252,11 @@ if ($_GET['action']=='edit')
 	}
 	elseif ($row['content']=='' AND $row['title']=='' AND $page=='index')
 	{
-		$content=sprintf(get_lang('DefaultContent'),api_get_path(WEB_IMG_PATH));
+		//Table structure for better export to pdf
+		$default_table_for_content_Start='<table align="center" border="0"><tr><td align="center">';
+		$default_table_for_content_End='</td></tr></table>';
+		
+		$content=$default_table_for_content_Start.sprintf(get_lang('DefaultContent'),api_get_path(WEB_IMG_PATH)).$default_table_for_content_End;
 		$title=get_lang('DefaultTitle');
 		$page_id=0;
 	}

+ 5 - 1
main/wiki/wiki.inc.php

@@ -784,7 +784,11 @@ function display_wiki_entry()
 	{
 		if(api_is_allowed_to_edit() || api_is_platform_admin() || GroupManager :: is_user_in_group(api_get_user_id(),$_SESSION['_gid'])) 
 		{
-			$content=sprintf(get_lang('DefaultContent'),api_get_path(WEB_IMG_PATH));
+			//Table structure for better export to pdf
+			$default_table_for_content_Start='<table align="center" border="0"><tr><td align="center">';
+			$default_table_for_content_End='</td></tr></table>';
+		
+			$content=$default_table_for_content_Start.sprintf(get_lang('DefaultContent'),api_get_path(WEB_IMG_PATH)).$default_table_for_content_End;
 			$title=get_lang('DefaultTitle');
 		}
 		else