2 /* vim: set expandtab sw=4 ts=4 sts=4: */
5 * @package phpMyAdmin-Designer
11 require_once "./pmd_common.php";
13 $tab_column = get_tab_info();
14 $script_tabs = get_script_tabs();
15 $script_contr = get_script_contr();
16 $tab_pos = get_tab_pos();
17 $tables_pk_or_unique_keys = get_pk_or_unique_keys();
18 $tables_all_keys = get_all_keys();
22 <!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
23 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
24 <html xmlns
:v
="urn:schemas-microsoft-com:vml" xmlns
="http://www.w3.org/1999/xhtml" xml
:lang
="<?php echo $GLOBALS['available_languages'][$GLOBALS['lang']][1]; ?>" lang
="<?php echo $GLOBALS['available_languages'][$GLOBALS['lang']][1]; ?>" dir
="<?php echo $GLOBALS['text_dir']; ?>">
26 <meta http
-equiv
="Content-Type" content
="text/html; charset=<?php echo $charset ?>" />
27 <link rel
="icon" href
="pmd/images/favicon.ico" type
="image/x-icon" />
28 <link rel
="shortcut icon" href
="pmd/images/favicon.ico" type
="image/x-icon" />
29 <link rel
="stylesheet" type
="text/css" href
="pmd/styles/<?php echo $GLOBALS['PMD']['STYLE'] ?>/style1.css" />
30 <title
>Designer
</title
>
31 <script src
="./js/jquery/jquery-1.4.2.js" type
="text/javascript"></script
>
32 <script type
="text/javascript">
36 var server = "' . PMA_escapeJsString($server) . '";
37 var db = "' . PMA_escapeJsString($db) . '";
38 var token = "' . PMA_escapeJsString($token) . '";';
40 if($_REQUEST['query']) {
42 $(document).ready(function(){
43 $(".trigger").click(function(){
44 $(".panel").toggle("fast");
45 $(this).toggleClass("active");
54 $params = array('lang' => $GLOBALS['lang']);
55 if (isset($GLOBALS['db'])) {
56 $params['db'] = $GLOBALS['db'];
59 <script src
="js/messages.php<?php echo PMA_generate_common_url($params); ?>" type
="text/javascript"></script
>
60 <script src
="pmd/scripts/ajax.js" type
="text/javascript"></script
>
61 <script src
="pmd/scripts/history.js" type
="text/javascript"></script
>
62 <script src
="pmd/scripts/move.js" type
="text/javascript"></script
>
64 <script src
="pmd/scripts/iecanvas.js" type
="text/javascript"></script
>
67 echo $script_tabs . $script_contr . $script_display_field;
71 <body onload
="Main()" class="general_body" id
="pmd_body">
73 <div
class="header" id
="top_menu">
74 <a href
="javascript:Show_left_menu(document.getElementById('key_Show_left_menu'));"
75 onmousedown
="return false;" class="M_butt first" target
="_self">
76 <img id
='key_Show_left_menu' title
="<?php echo __('Show/Hide left menu'); ?>"
77 alt
="v" src
="pmd/images/downarrow2_m.png" /></a
>
78 <a href
="javascript:Save2();" onmousedown
="return false;"
79 class="M_butt" target
="_self"
80 ><img title
="<?php echo __('Save position') ?>" src
="pmd/images/save.png" alt
=""
81 /></a
><a href
="javascript:Start_table_new();" onmousedown
="return false;"
82 class="M_butt" target
="_self"
83 ><img title
="<?php echo __('Create table')?>" src
="pmd/images/table.png" alt
=""
84 /></a
><a href
="javascript:Start_relation();" onmousedown
="return false;"
85 class="M_butt" id
="rel_button" target
="_self"
86 ><img title
="<?php echo __('Create relation') ?>" src
="pmd/images/relation.png" alt
=""
87 /></a
><a href
="javascript:Start_display_field();" onmousedown
="return false;"
88 class="M_butt" id
="display_field_button" target
="_self"
89 ><img title
="<?php echo __('Choose column to display') ?>" src
="pmd/images/display_field.png" alt
=""
90 /></a
><a href
="javascript:location.reload();" onmousedown
="return false;"
91 class="M_butt" target
="_self"
92 ><img title
="<?php echo __('Reload'); ?>" src
="pmd/images/reload.png" alt
=""
93 /></a
><a href
="javascript:Help();" onmousedown
="return false;"
94 class="M_butt" target
="_self"
95 ><img title
="<?php echo __('Help'); ?>" src
="pmd/images/help.png" alt
=""
96 /></a
><img
class="M_bord" src
="pmd/images/bord.png" alt
=""
97 /><a href
="javascript:Angular_direct();" onmousedown
="return false;"
98 class="M_butt" id
="angular_direct_button" target
="_self"
99 ><img title
="<?php echo __('Angular links') . ' / ' . __('Direct links'); ?>"
100 src
="pmd/images/ang_direct.png" alt
=""
101 /></a
><a href
="javascript:Grid();" onmousedown
="return false;"
102 class="M_butt" id
="grid_button" target
="_self"
103 ><img title
="<?php echo __('Snap to grid') ?>" src
="pmd/images/grid.png" alt
=""
104 /></a
><img
class="M_bord" src
="pmd/images/bord.png" alt
=""
105 /><a href
="javascript:Small_tab_all(document.getElementById('key_SB_all'));"
106 onmousedown
="return false;" class="M_butt" target
="_self"
107 ><img id
='key_SB_all' title
="<?php echo __('Small/Big All'); ?>" alt
="v"
108 src
="pmd/images/downarrow1.png"
109 /></a
><a href
="javascript:Small_tab_invert();" onmousedown
="return false;"
110 class="M_butt" target
="_self"
111 ><img title
="<?php echo __('Toggle small/big'); ?>" alt
="key" src
="pmd/images/bottom.png"
112 /></a
><img
class="M_bord" src
="pmd/images/bord.png" alt
=""
113 /><a href
="javascript:build_query()" onmousedown
="return false;"
114 class="M_butt" target
="_self"
115 ><img src
="pmd/images/pdf.png" alt
="key" width
="20" height
="20"
116 title
="<?php echo __('Import/Export coordinates for PDF schema'); ?>" /></a
>
117 <a href
="javascript:Top_menu_right(document.getElementById('key_Left_Right'));"
118 onmousedown
="return false;" class="M_butt last" target
="_self">
119 <img src
="pmd/images/2rightarrow_m.png" id
="key_Left_Right" alt
=">"
120 title
="<?php echo __('Move Menu'); ?>" /></a
>
124 <CANVAS id
="canvas" width
="100" height
="100" onclick
="Canvas_click(this)"></CANVAS
>
127 <form action
="" method
="post" name
="form1">
128 <div id
="layer_menu" style
="visibility:<?php echo $hidden ?>;">
129 <div align
="center" style
="padding-top:5px;">
130 <a href
="javascript:Hide_tab_all(document.getElementById('key_HS_all'));"
131 onmousedown
="return false;" class="M_butt" target
="_self">
132 <img title
="<?php echo __('Hide/Show all'); ?>" alt
="v"
133 src
="pmd/images/downarrow1.png" id
='key_HS_all' /></a
>
134 <a href
="javascript:No_have_constr(document.getElementById('key_HS'));"
135 onmousedown
="return false;" class="M_butt" target
="_self">
136 <img title
="<?php echo __('Hide/Show Tables with no relation'); ?>" alt
="v"
137 src
="pmd/images/downarrow2.png" id
='key_HS' /></a
>
140 <div id
="id_scroll_tab" class="scroll_tab">
141 <table width
="100%" style
="padding-left: 3px;">
143 $name_cnt = count($GLOBALS['PMD']['TABLE_NAME']);
144 for ($i = 0; $i < $name_cnt; $i++
) {
146 <tr
><td title
="<?php echo __('Structure'); ?>" width
="1px"
147 onmouseover
="this.className='L_butt2_2'"
148 onmouseout
="this.className='L_butt2_1'">
149 <img onclick
="Start_tab_upd('<?php echo $GLOBALS['PMD_URL']["TABLE_NAME_SMALL
"][$i]; ?>');"
150 src
="pmd/images/exec.png" alt
="" /></td
>
152 <input onclick
="VisibleTab(this,'<?php echo $GLOBALS['PMD_URL']["TABLE_NAME
"][$i]; ?>')"
153 title
="<?php echo __('Hide'); ?>"
154 id
="check_vis_<?php echo $GLOBALS['PMD_URL']["TABLE_NAME
"][$i]; ?>"
155 style
="margin:0px;" type
="checkbox"
156 value
="<?php echo $GLOBALS['PMD_URL']["TABLE_NAME
"][$i]; ?>"
158 if (isset($tab_pos[$GLOBALS['PMD']["TABLE_NAME"][$i]])) {
159 echo $tab_pos[$GLOBALS['PMD']["TABLE_NAME"][$i]]["H"] ?
'checked="checked"' : '';
161 echo 'checked="checked"';
164 <td
class="Tabs" onmouseover
="this.className='Tabs2'"
165 onmouseout
="this.className='Tabs'"
166 onclick
="Select_tab('<?php echo $GLOBALS['PMD_URL']["TABLE_NAME
"][$i]; ?>');">
167 <?php
echo $GLOBALS['PMD_OUT']["TABLE_NAME"][$i]; ?
></td
>
176 <?php
echo __('Number of tables') . ': ' . $name_cnt; ?
>
179 <div id
="layer_menu_sizer" onmousedown
="layer_menu_cur_click=1">
184 for ($i = 0; $i < count($GLOBALS['PMD']["TABLE_NAME"]); $i++
) {
185 $t_n = $GLOBALS['PMD']["TABLE_NAME"][$i];
186 $t_n_url = $GLOBALS['PMD_URL']["TABLE_NAME"][$i];
189 <input name
="t_x[<?php echo $t_n_url ?>]" type
="hidden" id
="t_x_<?php echo $t_n_url ?>_" />
190 <input name
="t_y[<?php echo $t_n_url ?>]" type
="hidden" id
="t_y_<?php echo $t_n_url ?>_" />
191 <input name
="t_v[<?php echo $t_n_url ?>]" type
="hidden" id
="t_v_<?php echo $t_n_url ?>_" />
192 <input name
="t_h[<?php echo $t_n_url ?>]" type
="hidden" id
="t_h_<?php echo $t_n_url ?>_" />
194 <table id
="<?php echo $t_n_url ?>" cellpadding
="0" cellspacing
="0" class="tab"
195 style
="position: absolute;
196 left: <?php if (isset($tab_pos[$t_n])) echo $tab_pos[$t_n]["X
"]; else echo rand(180, 800); ?>px;
197 top: <?php if (isset($tab_pos[$t_n])) echo $tab_pos[$t_n]["Y
"]; else echo rand(30, 500); ?>px;
198 visibility: <?php if (isset($tab_pos[$t_n])) echo $tab_pos[$t_n]["H
"] ? "visible
" : "hidden
"; ?>;
203 if(isset($_REQUEST['query'])) {
204 echo '<td class="select_all">';
205 echo '<input type="checkbox" value="select_all_'.htmlspecialchars($t_n_url).'" style="margin: 0px;" ';
206 echo 'id="select_all_'.htmlspecialchars($t_n_url).'" title="select all" ';
207 echo 'onclick="Select_all(\''. htmlspecialchars($t_n_url) .'\',\''.htmlspecialchars($GLOBALS['PMD_OUT']["OWNER"][$i]).'\')"></td>';
209 <td
class="small_tab" onmouseover
="this.className='small_tab2';"
210 onmouseout
="this.className='small_tab';"
211 id
="id_hide_tbody_<?php echo $t_n_url ?>"
212 onclick
="Small_tab('<?php echo $t_n_url ?>', 1)"><?php
213 // no space alloawd here, between tags and content !!!
214 // JavaScript function does require this
215 if (! isset($tab_pos[$t_n]) ||
! empty($tab_pos[$t_n]["V"])) {
221 <td
class="small_tab_pref" onmouseover
="this.className='small_tab_pref2';"
222 onmouseout
="this.className='small_tab_pref';"
223 onclick
="Start_tab_upd('<?php echo $GLOBALS['PMD_URL']["TABLE_NAME_SMALL
"][$i]; ?>');">
224 <img src
="pmd/images/exec_small.png" alt
="" /></td
>
225 <td nowrap
="nowrap" id
="id_zag_<?php echo $t_n_url ?>" class="tab_zag"
226 onmousedown
="cur_click=document.getElementById('<?php echo $t_n_url ?>');"
227 onmouseover
="Table_onover('<?php echo $t_n_url ?>',0)"
228 onmouseout
="Table_onover('<?php echo $t_n_url ?>',1)">
231 echo $GLOBALS['PMD_OUT']["OWNER"][$i];
233 echo $GLOBALS['PMD_OUT']["TABLE_NAME_SMALL"][$i];
236 if(isset($_REQUEST['query'])) {
237 echo '<td class="tab_zag" onmouseover="Table_onover(\''.htmlspecialchars($t_n_url).'\',0)" id="id_zag_'.htmlspecialchars($t_n_url).'_2"';
238 echo 'onmousedown="cur_click=document.getElementById(\''.htmlspecialchars($t_n_url).'\');"';
239 echo 'onmouseout="Table_onover(\''.htmlspecialchars($t_n_url).'\',1)">';
243 <tbody id
="id_tbody_<?php echo $t_n_url ?>"
244 <?php
if ( isset($tab_pos[$t_n])) echo 'style="display: none;"'; ?
>>
246 $display_field = PMA_getDisplayField($db, $GLOBALS['PMD']["TABLE_NAME_SMALL"][$i]);
247 for ($j = 0, $id_cnt = count($tab_column[$t_n]["COLUMN_ID"]); $j < $id_cnt; $j++
) {
250 echo $GLOBALS['PMD_URL']["TABLE_NAME_SMALL
"][$i] . '.'
251 . urlencode($tab_column[$t_n]["COLUMN_NAME
"][$j]) ?>"
253 if ($display_field == $tab_column[$t_n]["COLUMN_NAME"][$j]) {
254 echo ' class="tab_field_3" ';
256 echo ' class="tab_field" ';
259 onmouseover
="old_class = this.className; this.className = 'tab_field_2';"
260 onmouseout
="this.className = old_class;"
261 onmousedown
="Click_field('<?php
262 echo $GLOBALS['PMD_URL']["TABLE_NAME_SMALL
"][$i]."','".urlencode($tab_column[$t_n]["COLUMN_NAME
"][$j])."',";
263 if (! PMA_foreignkey_supported($GLOBALS['PMD
']['TABLE_TYPE
'][$i])) {
264 echo (isset($tables_pk_or_unique_keys[$t_n . "." . $tab_column[$t_n]["COLUMN_NAME"][$j]]) ? 1 : 0);
266 // if foreign keys are supported, it's not necessary that the
267 // index is a primary key
268 echo (isset($tables_all_keys[$t_n.".".$tab_column[$t_n]["COLUMN_NAME"][$j]]) ?
1 : 0);
272 if(isset($_REQUEST['query'])) {
273 echo '<td class="select_all
">';
274 echo '<input value="'.htmlspecialchars($t_n_url).urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]).'"';
275 echo 'type="checkbox
" id="select_
'.htmlspecialchars($t_n_url).'._
'.urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]).'" ';
276 echo 'style="margin
: 0px
;" title="select_
'.urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]).'" ';
277 echo 'onclick="store_column(\''.urlencode($GLOBALS['PMD_OUT
']["TABLE_NAME_SMALL"][$i]).'\'
,\''.htmlspecialchars($GLOBALS['PMD_OUT
']["OWNER"][$i]).'\'
,\''.urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]).'\'
)"></td>';
279 <td width="10px
" colspan="3"
280 id="<?php
echo $t_n_url.".".urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]) ?
>">
281 <div style="white
-space
:nowrap
">
283 if (isset($tables_pk_or_unique_keys[$t_n.".".$tab_column[$t_n]["COLUMN_NAME
"][$j]])) {
285 <img src="pmd
/styles
/<?php
echo $GLOBALS['PMD']['STYLE'];?
>/images
/FieldKey_small
.png
"
290 <img src="pmd
/styles
/<?php
echo $GLOBALS['PMD']['STYLE']?
>/images
/Field_small
<?php
291 if (strstr($tab_column[$t_n]["TYPE"][$j],'char')
292 ||
strstr($tab_column[$t_n]["TYPE"][$j],'text')) {
294 } elseif (strstr($tab_column[$t_n]["TYPE"][$j],'int')
295 ||
strstr($tab_column[$t_n]["TYPE"][$j],'float')
296 ||
strstr($tab_column[$t_n]["TYPE"][$j],'double')
297 ||
strstr($tab_column[$t_n]["TYPE"][$j],'decimal')) {
299 } elseif (strstr($tab_column[$t_n]["TYPE"][$j],'date')
300 ||
strstr($tab_column[$t_n]["TYPE"][$j],'time')
301 ||
strstr($tab_column[$t_n]["TYPE"][$j],'year')) {
307 echo htmlspecialchars($tab_column[$t_n]["COLUMN_NAME
"][$j]
308 . " : " . $tab_column[$t_n]["TYPE
"][$j], ENT_QUOTES);
313 if(isset($_REQUEST['query'])) {
314 //$temp = $GLOBALS['PMD_OUT']["OWNER
"][$i].'.'.$GLOBALS['PMD_OUT']["TABLE_NAME_SMALL
"][$i];
315 echo '<td class="small_tab_pref
" onmouseover="this
.className
=\'small_tab_pref2\'
;"';
316 echo 'onmouseout="this
.className
=\'small_tab_pref\'
;"';
317 echo 'onclick="Click_option(\'pmd_optionse\'
,\''.urlencode($tab_column[$t_n]["COLUMN_NAME"][$j]).'\'
,\''.$GLOBALS['PMD_OUT
']["TABLE_NAME_SMALL"][$i].'\'
)" >';
318 echo '<img src="pmd
/images
/exec_small
.png
" title="options
" alt="" /></td> ';
330 <div id="hint
"></div>
331 <div id='layer_action' style="visibility
:<?php
echo $hidden ?
>;">Load...</div>
333 <table id="layer_new_relation
" style="visibility
:<?php
echo $hidden ?
>;"
334 width="5%
" border="0" cellpadding="0" cellspacing="0">
337 <td class="frams1
" width="10px
"></td>
338 <td class="frams5
" width="99%
" ></td>
339 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
342 <td class="frams8
"></td>
343 <td class="input_tab
">
344 <table width="168" border="0" align="center
" cellpadding="2" cellspacing="0">
347 <td colspan="2" align="center
" nowrap="nowrap
"><strong><?php echo __('Create relation'); ?></strong></td>
350 <tbody id="foreign_relation
">
352 <td colspan="2" align="center
" nowrap="nowrap
"><strong>FOREIGN KEY</strong></td>
355 <td width="58" nowrap="nowrap
">on delete</td>
356 <td width="102"><select name="on_delete
" id="on_delete
">
357 <option value="nix
" selected="selected
">--</option>
358 <option value="CASCADE
">CASCADE</option>
359 <option value="SET
NULL">SET NULL</option>
360 <option value="NO ACTION
">NO ACTION</option>
361 <option value="RESTRICT
">RESTRICT</option>
366 <td nowrap="nowrap
">on update</td>
367 <td><select name="on_update
" id="on_update
">
368 <option value="nix
" selected="selected
">--</option>
369 <option value="CASCADE
">CASCADE</option>
370 <option value="SET
NULL">SET NULL</option>
371 <option value="NO ACTION
">NO ACTION</option>
372 <option value="RESTRICT
">RESTRICT</option>
379 <td colspan="2" align="center
" nowrap="nowrap
">
380 <input type="button
" class="butt
" name="Button
"
381 value="<?php
echo __('OK'); ?
>" onclick="New_relation()" />
382 <input type="button
" class="butt
" name="Button
"
383 value="<?php
echo __('Cancel'); ?
>"
384 onclick="document
.getElementById('layer_new_relation').style
.visibility
= 'hidden';" />
390 <td class="frams6
"></td>
393 <td class="frams4
"><div class="bor
"></div></td>
394 <td class="frams7
"></td>
395 <td class="frams3
"></td>
400 <table id="layer_upd_relation
" style="visibility
:<?PHP
echo $hidden ?
>;"
401 width="5%
" border="0" cellpadding="0" cellspacing="0">
404 <td class="frams1
" width="10px
"></td>
405 <td class="frams5
" width="99%
"></td>
406 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
409 <td class="frams8
"></td>
410 <td class="input_tab
">
411 <table width="100%
" border="0" align="center
" cellpadding="2" cellspacing="0">
413 <td colspan="3" align="center
" nowrap="nowrap
"><strong><?php echo __('Delete relation'); ?></strong></td>
416 <td colspan="3" align="center
" nowrap="nowrap
">
417 <input name="Button
" type="button
" class="butt
"
418 onclick="Upd_relation()" value="<?php
echo __('Delete'); ?
>" />
419 <input type="button
" class="butt
" name="Button
"
420 value="<?php
echo __('Cancel'); ?
>"
421 onclick="document
.getElementById('layer_upd_relation').style
.visibility
= 'hidden'; Re_load();" />
425 <td class="frams6
"></td>
428 <td class="frams4
"><div class="bor
"></div></td>
429 <td class="frams7
"></td>
430 <td class="frams3
"></td>
435 <table id="pmd_optionse
" style="visibility
:<?php
echo $hidden ?
>;"
436 width="5%
" border="0" cellpadding="0" cellspacing="0">
439 <td class="frams1
" width="10px
"></td>
440 <td class="frams5
" width="99%
" ></td>
441 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
444 <td class="frams8
"></td>
445 <td class="input_tab
">
446 <table width="168" border="0" align="center
" cellpadding="2" cellspacing="0">
449 <td colspan="2" rowspan="2" id="option_col_name
" nowrap="nowrap
" align="center
"></td>
453 <tr><td align="center
" nowrap="nowrap
"><b>Where</b></td></tr>
455 <td width="58" nowrap="nowrap
">Relation operator</td>
456 <td width="102"><select name="rel_opt
" id="rel_opt
">
457 <option value="--" selected="selected
"> -- </option>
458 <option value="=" > = </option>
459 <option value=">"> > </option>
460 <option value="<"> < </option>
461 <option value=">="> >= </option>
462 <option value="<="> <= </option>
463 <option value="NOT
"> NOT </option>
464 <option value="IN
"> IN </option>
465 <option value="EXCEPT
"> Except </option>
466 <option value="NOT IN
"> Not In </option>
471 <td nowrap="nowrap
">Value/<br />Subquery</td>
472 <td><textarea id="Query
" value="" cols="18"></textarea>
475 <tr><td align="center
" nowrap="nowrap
"><b>Rename To</b></td></tr>
477 <td width="58" nowrap="nowrap
">New Name</td>
478 <td width="102"><input type="text
" value="" id="new_name
"/></td>
480 <tr><td align="center
" nowrap="nowrap
"><b>Aggregate</b></td></tr>
482 <td width="58" nowrap="nowrap
">Operator</td>
483 <td width="102"><select name="operator
" id="operator
">
484 <option value="---" selected="selected
">---</option>
485 <option value="sum
" > Sum </option>
486 <option value="min
"> Min </option>
487 <option value="max
"> Max </option>
488 <option value="avg
"> Avg </option>
489 <option value="avg
"> Count </option>
493 <td nowrap="nowrap
" width="58" align="center
"><b>Group By</b></td>
494 <td><input type="checkbox
" value="groupby
" id="groupby
"/></td>
497 <td nowrap="nowrap
" width="58" align="center
"><b>Order By</b></td>
498 <td><input type="checkbox
" value="orderby
" id="orderby
"/></td>
503 <td colspan="2" align="center
" nowrap="nowrap
">
504 <input type="button
" class="butt
" name="Button
"
505 value="<?php
echo __('OK'); ?
>" onclick="add_object()" />
506 <input type="button
" class="butt
" name="Button
"
507 value="<?php
echo __('Cancel'); ?
>"
508 onclick="Close_option()" />
514 <td class="frams6
"></td>
517 <td class="frams4
"><div class="bor
"></div></td>
518 <td class="frams7
"></td>
519 <td class="frams3
"></td>
524 <table id="query_rename_to
" style="visibility
:<?php
echo $hidden ?
>;"
525 width="5%
" border="0" cellpadding="0" cellspacing="0">
528 <td class="frams1
" width="10px
"></td>
529 <td class="frams5
" width="99%
" ></td>
530 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
533 <td class="frams8
"></td>
534 <td class="input_tab
">
535 <table width="168" border="0" align="center
" cellpadding="2" cellspacing="0">
538 <td colspan="2" align="center
" nowrap="nowrap
"><strong>Rename To</strong></td>
541 <tbody id="rename_to
">
543 <td width="58" nowrap="nowrap
">New Name</td>
545 <input type="text
" value="" id="e_rename
"/>
551 <td colspan="2" align="center
" nowrap="nowrap
">
552 <input type="button
" class="butt
" name="Button
"
553 value="<?php
echo __('OK'); ?
>" onclick="edit('Rename')" />
554 <input type="button
" class="butt
" name="Button
"
555 value="<?php
echo __('Cancel'); ?
>"
556 onclick="document
.getElementById('query_rename_to').style
.visibility
= 'hidden';" />
562 <td class="frams6
"></td>
565 <td class="frams4
"><div class="bor
"></div></td>
566 <td class="frams7
"></td>
567 <td class="frams3
"></td>
572 <table id="query_Aggregate
" style="visibility
:<?php
echo $hidden ?
>;"
573 width="5%
" border="0" cellpadding="0" cellspacing="0">
576 <td class="frams1
" width="10px
"></td>
577 <td class="frams5
" width="99%
" ></td>
578 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
581 <td class="frams8
"></td>
582 <td class="input_tab
">
583 <table width="168" border="0" align="center
" cellpadding="2" cellspacing="0">
586 <td colspan="2" align="center
" nowrap="nowrap
"><strong>Aggregate</strong></td>
591 <td width="58" nowrap="nowrap
">Operator</td>
593 <select name="operator
" id="e_operator
">
594 <option value="---" selected="selected
">---</option>
595 <option value="sum
" > Sum </option>
596 <option value="min
"> Min </option>
597 <option value="max
"> Max </option>
598 <option value="avg
"> Avg </option>
599 <option value="avg
"> Count </option>
605 <td colspan="2" align="center
" nowrap="nowrap
">
606 <input type="button
" class="butt
" name="Button
"
607 value="<?php
echo __('OK'); ?
>" onclick="edit('Aggregate')" />
608 <input type="button
" class="butt
" name="Button
"
609 value="<?php
echo __('Cancel'); ?
>"
610 onclick="document
.getElementById('query_Aggregate').style
.visibility
= 'hidden';" />
616 <td class="frams6
"></td>
619 <td class="frams4
"><div class="bor
"></div></td>
620 <td class="frams7
"></td>
621 <td class="frams3
"></td>
626 <table id="query_where
" style="visibility
:<?php
echo $hidden ?
>;"
627 width="5%
" border="0" cellpadding="0" cellspacing="0">
630 <td class="frams1
" width="10px
"></td>
631 <td class="frams5
" width="99%
" ></td>
632 <td class="frams2
" width="10px
"><div class="bor
"></div></td>
635 <td class="frams8
"></td>
636 <td class="input_tab
">
637 <table width="168" border="0" align="center
" cellpadding="2" cellspacing="0">
640 <td colspan="2" align="center
" nowrap="nowrap
"><strong>Where</strong></td>
643 <tbody id="rename_to
">
645 <td width="58" nowrap="nowrap
">Opeartor</td>
646 <td width="102"><select name="erel_opt
" id="erel_opt
">
647 <option value="--" selected="selected
"> -- </option>
648 <option value="=" > = </option>
649 <option value=">"> > </option>
650 <option value="<"> < </option>
651 <option value=">="> >= </option>
652 <option value="<="> <= </option>
653 <option value="NOT
"> NOT </option>
654 <option value="IN
"> IN </option>
655 <option value="EXCEPT
"> Except </option>
656 <option value="NOT IN
"> Not In </option>
661 <td nowrap="nowrap
">Value/<br />Subquery</td>
662 <td><textarea id="eQuery
" value="" cols="18"></textarea>
668 <td colspan="2" align="center
" nowrap="nowrap
">
669 <input type="button
" class="butt
" name="Button
"
670 value="<?php
echo __('OK'); ?
>" onclick="edit('Where')" />
671 <input type="button
" class="butt
" name="Button
"
672 value="<?php
echo __('Cancel'); ?
>"
673 onclick="document
.getElementById('query_where').style
.visibility
= 'hidden';" />
679 <td class="frams6
"></td>
682 <td class="frams4
"><div class="bor
"></div></td>
683 <td class="frams7
"></td>
684 <td class="frams3
"></td>
690 if($_REQUEST['query']) {
691 echo '<div class="panel
">';
692 echo '<div style="clear
:both
;"></div>';
693 echo '<div id="ab
"></div>';
694 echo '<div style="clear
:both
;"></div>';
696 echo '<a class="trigger
" href="#">History</a>';
698 <!-- cache images
-->
699 <img src
="pmd/images/2leftarrow_m.png" width
="0" height
="0" alt
="" />
700 <img src
="pmd/images/rightarrow1.png" width
="0" height
="0" alt
="" />
701 <img src
="pmd/images/rightarrow2.png" width
="0" height
="0" alt
="" />
702 <img src
="pmd/images/uparrow2_m.png" width
="0" height
="0" alt
="" />