phpMyEdit - Viewing Bug Advanced Details [ Go Back ]
432 extension related minor always 2007-01-25 18:49 2007-01-25 18:49
kinalus  
 
normal  
new 5.6 (stable)  
open  
none  
none  
Class phpMyEdit-mce-cal doesn't include PHP code when using the PHP extension
When using the phpMyEdit_mce_cal, fields using the PHP extension, (i.e. $opts['fdd']['field']['php'] = 'phpcode.inc') are not displayed properly on operations Add, Change.
Declare a field that uses the PHP extension:
<pre>
$opts['fdd']['field']['php'] = 'phpcode.inc'
</pre>
create the file phpcode.inc, e.g.:
<pre>
<?php
$output = "";
if (isset($_POST['PME_sys_operation'])) {
$operation = $_POST['PME_sys_operation'];
} else {
$operation = "";
}
$output.= "Op=".$operation;
$output .= " Value=".$row["qf$k"];

return $output;
?>
</pre>

Then try to change a record, the particular field will not display "Op=Change Value=..." but the usual form input.
The appropriate code that handles the PHP extension case is not included in the class code. In functions display_add_record(), display_change_field($row, $k) users can add the following two lines (taken from phpMyEdit.class.php):
<pre>
} elseif ($this->col_has_php($k)) {
echo include($this->fdd[$k]['php']);
</pre>
after lines 388, 460 to correct this problem.
0000432-phpMyEdit-mce-cal.class.php.txt (18 KB) 1970-01-01 01:33

There are no notes attached to this bug.