PMA_table_info

This commit is contained in:
Marc Delisle
2002-05-22 11:38:43 +00:00
parent fa99903bba
commit fceeed331d
5 changed files with 19 additions and 13 deletions

View File

@@ -5,6 +5,12 @@ phpMyAdmin - Changelog
$Id$
$Source$
2002-05-22 Marc Delisle <lem9@users.sourceforge.net>
* Documentation.html, config.inc.php3, db_details_structure.php3,
pdf_schema.php3: PMA_pdf_table_position renamed
to PMA_table_info, because "foreign_display_field" will move from
PMA_relation to PMA_table_info (once per table)
2002-05-21 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* ldi_table.php3, line 44: beautified generated html.
* tbl_properties_options.php3: fixed display errors with IE5.

View File

@@ -656,10 +656,10 @@ $cfg['PmaAbsoluteUri'] = (!empty($HTTPS) ? 'https' : 'http') . '://'
</dd>
<dt>
<b>$cfg['Servers'][$i]['pdf_table_position']</b> string
<b>$cfg['Servers'][$i]['table_info']</b> string
</dt>
<dd>
Since release 2.3.0 you can describe, in a special 'pdf_table_position'
Since release 2.3.0 you can describe, in a special 'table_info'
table, the coordinates where each table will be placed on a PDF schema
output. This configuration variable will hold the name of this special
table.
@@ -671,20 +671,20 @@ $cfg['PmaAbsoluteUri'] = (!empty($HTTPS) ? 'https' : 'http') . '://'
To use this functionality you have to:
<ul>
<li>
create in the same database a table (for example 'PMA_pdf_table_position')
create in the same database a table (for example 'PMA_table_info')
following this scheme:<br />
<tt>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CREATE TABLE `PMA_pdf_table_position` (<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CREATE TABLE `PMA_table_info` (<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`table_name` varchar(64) NOT NULL default '',<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`x` float unsigned NOT NULL default '0',<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;`y` float unsigned NOT NULL default '0',<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;PRIMARY KEY (`table_name`)<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;) TYPE=MyISAM COMMENT='Table positions for PDF schema';<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;) TYPE=MyISAM COMMENT='Table information for phpMyAdmin';<br />
</tt>
</li>
<li>
put the table name in
<tt>$cfg['Servers'][$i]['pdf_table_position']</tt>
<tt>$cfg['Servers'][$i]['table_info']</tt>
</li>
<li>
then manually fill this table with information about the table
@@ -1772,14 +1772,14 @@ $cfg['PmaAbsoluteUri'] = (!empty($HTTPS) ? 'https' : 'http') . '://'
<p>
<b>How can I produce a PDF schema of my database?</b>
<br />
First you have to fill the 'relation' and 'pdf_table_position'
First you have to fill the 'relation' and 'table_info'
configuration variables.
<br /><br />
Then, think about your schema layout: which tables will go on which pages.
You have to fill in the 'relation' table the page number for each
master-foreign link.
<br /><br />
Then manually fill the pdf_table_position table with the coordinates,
Then manually fill the table_info table with the coordinates,
x being the width and y the height, and (0,0) at the upper left corner.
For example, x=100 and y=200 means that the table will be at 200 mm down
and 100 mm right from the upper left corner.

View File

@@ -50,7 +50,7 @@ $cfg['Servers'][$i]['bookmarkdb'] = ''; // Bookmark db - leave blank
$cfg['Servers'][$i]['bookmarktable'] = ''; // Bookmark table - leave blank for no bookmark support
$cfg['Servers'][$i]['relation'] = ''; // table to describe the relation between links (see doc)
// - leave blank for no relation-links support
$cfg['Servers'][$i]['pdf_table_position']
$cfg['Servers'][$i]['table_info']
= ''; // table to describe the
// tables position for the
// PDF schema - leave blank
@@ -76,7 +76,7 @@ $cfg['Servers'][$i]['verbose'] = '';
$cfg['Servers'][$i]['bookmarkdb'] = '';
$cfg['Servers'][$i]['bookmarktable'] = '';
$cfg['Servers'][$i]['relation'] = '';
$cfg['Servers'][$i]['pdf_table_position']
$cfg['Servers'][$i]['table_info']
= '';
$cfg['Servers'][$i]['AllowDeny']['order']
= '';
@@ -98,7 +98,7 @@ $cfg['Servers'][$i]['verbose'] = '';
$cfg['Servers'][$i]['bookmarkdb'] = '';
$cfg['Servers'][$i]['bookmarktable'] = '';
$cfg['Servers'][$i]['relation'] = '';
$cfg['Servers'][$i]['pdf_table_position']
$cfg['Servers'][$i]['table_info']
= '';
$cfg['Servers'][$i]['AllowDeny']['order']
= '';

View File

@@ -438,7 +438,7 @@ echo ' ' . '&nbsp;<input type="submit" value="' . $strGo . '" />' . "\n";
<?php
// is this OK to check for 'class' support?
if (PMA_PHP_INT_VERSION >= 40000
&& (!empty($cfg['Server']['pdf_table_position']))
&& (!empty($cfg['Server']['table_info']))
&& $num_tables > 0) {
?>
<!-- PDF schema -->

View File

@@ -380,7 +380,7 @@ class PMA_RT_Table
//x and y
$sql = 'SELECT x, y FROM '
. PMA_backquote($GLOBALS['cfg']['Server']['pdf_table_position'])
. PMA_backquote($GLOBALS['cfg']['Server']['table_info'])
. ' WHERE table_name = \'' . PMA_sqlAddslashes($table_name) . '\'';
$result = mysql_query($sql);
if (!$result || !mysql_num_rows($result)) {