if ($edit_preview) {
     $content = $edit_file_content;
     html_break(1);
     html_text_bold(lang('Preview of %1', $path . '/' . $edit_file));
     html_break(2);
     html_table_begin('90%');
     html_table_row_begin();
     html_table_col_begin();
     html_text(nl2br($content));
     html_table_col_end();
     html_table_row_end();
     html_table_end();
 } elseif ($edit_save) {
     $content = $edit_file_content;
     if ($GLOBALS['phpgw']->vfs->write(array('string' => $edit_file, 'relatives' => array(RELATIVE_ALL), 'content' => $content))) {
         html_text_bold(lang('Saved %1', $path . '/' . $edit_file));
         html_break(2);
         html_link_back();
     } else {
         html_text_error(lang('Could not save %1', $path . '/' . $edit_file));
         html_break(2);
         html_link_back();
     }
 }
 /* This doesn't work just yet
 	elseif ($edit_save_all)
 	{
 		for ($j = 0; $j != $numoffiles; $j++)
 		{
 			$fileman[$j];
 
Example #2
0
        echo "<br>{$sequence_num} - getabsolutepath - {$cd} (shouldn't matter) - {$i} - {$relatives['0']} - {$o} - {$ao}";
    }
}
# end of getabsolutepath tests
###
###
# start of path_parts tests
/* Just for convienience
$io = array ("" => array ("fake_full_path" => "", "fake_leading_dirs" => "", "fake_extra_path" => "", "fake_name" => "", "real_full_path" => "", "real_leading_dirs" => "", "real_extra_path" => "", "real_name" => ""));
`~!@#$%^&*()-_=+/|[{]};:'\",<.>?
*/
$sequence_num = 12;
$cd = "test8/test10";
$relatives[0] = RELATIVE_USER;
$phpgw->vfs->cd(array('string' => $cd, 'relative' => False, 'relatives' => array($relatives[0])));
$subhome = substr($homedir, 1);
$io = array("" => array("fake_full_path" => "{$homedir}/{$cd}", "fake_leading_dirs" => "{$homedir}/test8", "fake_extra_path" => "{$subhome}/test8", "fake_name" => "test10", "real_full_path" => "{$filesdir}{$homedir}/{$cd}", "real_leading_dirs" => "{$filesdir}{$homedir}/test8", "real_extra_path" => "{$subhome}/test8", "real_name" => "test10"), "dir2/file" => array("fake_full_path" => "{$homedir}/{$cd}/dir2/file", "fake_leading_dirs" => "{$homedir}/{$cd}/dir2", "fake_extra_path" => "{$subhome}/{$cd}/dir2", "fake_name" => "file", "real_full_path" => "{$filesdir}{$homedir}/{$cd}/dir2/file", "real_leading_dirs" => "{$filesdir}{$homedir}/{$cd}/dir2", "real_extra_path" => "{$subhome}/{$cd}/dir2", "real_name" => "file"), "`~!@#\$%^&*()-_=+/|[{]};:'\",<.>?" => array("fake_full_path" => "{$homedir}/{$cd}/`~!@#\$%^&*()-_=+/|[{]};:'\",<.>?", "fake_leading_dirs" => "{$homedir}/{$cd}/`~!@#\$%^&*()-_=+", "fake_extra_path" => "{$subhome}/{$cd}/`~!@#\$%^&*()-_=+", "fake_name" => "|[{]};:'\",<.>?", "real_full_path" => "{$filesdir}{$homedir}/{$cd}/`~!@#\$%^&*()-_=+/|[{]};:'\",<.>?", "real_leading_dirs" => "{$filesdir}{$homedir}/{$cd}/`~!@#\$%^&*()-_=+", "real_extra_path" => "{$subhome}/{$cd}/`~!@#\$%^&*()-_=+", "real_name" => "|[{]};:'\",<.>?"));
while (list($i, $o) = each($io)) {
    $ao = $phpgw->vfs->path_parts(array('string' => $i));
    while (list($key, $value) = each($o)) {
        if ($ao->{$key} != $o[$key]) {
            echo "<br>{$sequence_num} - path_parts - {$cd} - {$i} - {$relatives['0']} - {$key} - {$o[$key]} - {$ao[$key]}";
        }
    }
}
# end of path_parts tests
###
$phpgw->vfs->cd();
html_break(2);
html_text_bold("The less output, the better.  Please file errors as a " . html_link("https://sourceforge.net/tracker/?group_id=7305&atid=107305", "bug report", True, False) . ". Be sure to include the system information line at the top, and anything special about your setup.  Thanks!");
html_page_close();