' . "\n" . '' . $strDocu . '' . "\n"; exit(); } if (!$cfgRelation['displaywork']) { echo sprintf($strNotSet, 'table_info', 'config.inc.php3') . '
' . "\n" . '' . $strDocu . '' . "\n"; exit(); } if (!isset($cfgRelation['table_coords'])){ echo sprintf($strNotSet, 'table_coords', 'config.inc.php3') . '
' . "\n" . '' . $strDocu . '' . "\n"; exit(); } if (!isset($cfgRelation['pdf_pages'])) { echo sprintf($strNotSet, 'pdf_page', 'config.inc.php3') . '
' . "\n" . '' . $strDocu . '' . "\n"; exit(); } if ($cfgRelation['pdfwork']) { // Now is the time to work on all changes if (isset($do)) { switch ($do) { case 'choosepage': if ($action_choose=="1") { $ch_query = 'DELETE FROM ' . PMA_backquote($cfgRelation['table_coords']) . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\'' . ' AND pdf_page_number = ' . $chpage; PMA_query_as_cu($ch_query); $ch_query = 'DELETE FROM ' . PMA_backquote($cfgRelation['pdf_pages']) . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\'' . ' AND page_nr = ' . $chpage; PMA_query_as_cu($ch_query); } break; case 'createpage': if (!isset($newpage) || $newpage == '') { $newpage = $strNoDescription; } $ins_query = 'INSERT INTO ' . PMA_backquote($cfgRelation['pdf_pages']) . ' (db_name, page_descr)' . ' VALUES (\'' . PMA_sqlAddslashes($db) . '\', \'' . PMA_sqlAddslashes($newpage) . '\')'; PMA_query_as_cu($ins_query); break; case 'edcoord': for ($i = 0; $i < $c_table_rows; $i++) { $arrvalue = 'c_table_' . $i; $arrvalue = $$arrvalue; if (!isset($arrvalue['x']) || $arrvalue['x'] == '') { $arrvalue['x'] = 0; } if (!isset($arrvalue['y']) || $arrvalue['y'] == '') { $arrvalue['y'] = 0; } if (isset($arrvalue['name']) && $arrvalue['name'] != '--') { $test_query = 'SELECT * FROM ' . PMA_backquote($cfgRelation['table_coords']) . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\'' . ' AND table_name = \'' . PMA_sqlAddslashes($arrvalue['name']) . '\'' . ' AND pdf_page_number = ' . $chpage; $test_rs = PMA_query_as_cu($test_query); if ($test_rs && mysql_num_rows($test_rs) > 0) { if (isset($arrvalue['delete']) && $arrvalue['delete'] == 'y') { $ch_query = 'DELETE FROM ' . PMA_backquote($cfgRelation['table_coords']) . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\'' . ' AND table_name = \'' . PMA_sqlAddslashes($arrvalue['name']) . '\'' . ' AND pdf_page_number = ' . $chpage; } else { $ch_query = 'UPDATE ' . PMA_backquote($cfgRelation['table_coords']) . ' ' . 'SET x = ' . $arrvalue['x'] . ', y= ' . $arrvalue['y'] . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\'' . ' AND table_name = \'' . PMA_sqlAddslashes($arrvalue['name']) . '\'' . ' AND pdf_page_number = ' . $chpage; } } else { $ch_query = 'INSERT INTO ' . PMA_backquote($cfgRelation['table_coords']) . ' ' . '(db_name, table_name, pdf_page_number, x, y) ' . 'VALUES (\'' . PMA_sqlAddslashes($db) . '\', \'' . PMA_sqlAddslashes($arrvalue['name']) . '\',' . $chpage . ',' . $arrvalue['x'] . ',' . $arrvalue['y'] . ')'; } PMA_query_as_cu($ch_query); } // end if } // end for break; } // end switch } // end if (isset($do)) // We will need an array of all tables in this db $selectboxall[] = '--'; $alltab_qry = 'SHOW TABLES FROM ' . PMA_backquote($db); $alltab_rs = @PMA_mysql_query($alltab_qry) or PMA_mysqlDie('', $alltab_qry, '', $err_url_0); while (list($table) = @PMA_mysql_fetch_array($alltab_rs)) { $selectboxall[] = $table; } // Now first show some possibility to choose a page for the pdf $page_query = 'SELECT * FROM ' . PMA_backquote($cfgRelation['pdf_pages']) . ' WHERE db_name = \'' . PMA_sqlAddslashes($db) . '\''; $page_rs = PMA_query_as_cu($page_query); if ($page_rs && mysql_num_rows($page_rs) > 0) { ?>
0) { echo "\n"; ?>

'; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; $i++; } // end while // Do one more empty row echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . '
X Y
' . "\n" . ' ' . "\n" . ' ' . "\n" . ' ' . $strDelete; echo "\n" . ' ' . "\n" . ' '; echo "\n" . ' ' . "\n" . ' '; echo "\n" . '
' . "\n" . ' ' . "\n" . ' ' . "\n" . ' ' . $strDelete; echo "\n" . ' ' . "\n" . ' '; echo "\n" . ' ' . "\n" . ' '; echo "\n" . '
' . "\n"; echo "\n" . ' '; echo "\n" . ' '; echo "\n" . '
' . "\n\n"; } // end if if (isset($do) && ($do == 'edcoord' || $do == 'choosepage')) { ?>
 :