| version 1.130, 2004/04/04 21:02:57 |
version 1.131, 2004/04/12 12:02:04 |
|
|
| * http://platon.sk/projects/phpMyEdit/ |
* http://platon.sk/projects/phpMyEdit/ |
| */ |
*/ |
| |
|
| /* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.129 2004/03/31 15:46:26 nepto Exp $ */ |
/* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.130 2004/04/04 21:02:57 nepto Exp $ */ |
| |
|
| /* This is a generic table editing program. The table and fields to be |
/* This is a generic table editing program. The table and fields to be |
| edited are defined in the calling program. |
edited are defined in the calling program. |
|
|
| for ($k = 0, $numfds = sizeof($this->fds); $k < $numfds; $k++) { |
for ($k = 0, $numfds = sizeof($this->fds); $k < $numfds; $k++) { |
| $main_column = $this->fds[$k]; |
$main_column = $this->fds[$k]; |
| if($this->fdd[$main_column]['values']['db']) { |
if($this->fdd[$main_column]['values']['db']) { |
| $db = $this->fdd[$field]['values']['db']; |
$db = $this->fdd[$main_column]['values']['db']; |
| } else { |
} else { |
| $db = $this->db; |
$db = $this->db; |
| } |
} |
|
|
| 'join_column' => $join_column, |
'join_column' => $join_column, |
| 'join_description' => $join_desc); |
'join_description' => $join_desc); |
| $join_clause .= " LEFT OUTER JOIN $db.$table AS $join_table ON "; |
$join_clause .= " LEFT OUTER JOIN $db.$table AS $join_table ON "; |
| $join_clause .= isset($this->fdd[$field]['values']['join']) |
$join_clause .= isset($this->fdd[$main_column]['values']['join']) |
| ? $this->substituteVars($this->fdd[$field]['values']['join'], $ar) |
? $this->substituteVars($this->fdd[$main_column]['values']['join'], $ar) |
| : "$join_table.$join_column = $main_table.$main_column"; |
: "$join_table.$join_column = $main_table.$main_column"; |
| $tbs[] = $join_table; |
$tbs[] = $join_table; |
| } |
} |