Gossamer Forum
Home : Products : Others : Fileman :

Unable to opening Binary Files???

Quote Reply
Unable to opening Binary Files???
I have some binary files located in the directory tree stucture of Fileman. These files are Word Perfect and Miscrosoft products such as Microsoft Word. An error occurred when, for example, a Miscrosoft Word document was double clicked. I modified the code to include the appropriate href to the %config (the bin_url to use file://). It fixed the problem....when the file was double clicked the system launches Microsoft Word containing the contents of the Word document selected. The problem I am having is any binary file works when the files are accessed within the server domain. But, when fileman is used outside the server domain it get the following error: "Netscape is unable to find the file or directory named .....blah blah blah". Below is a snipped of code for binary files. again it works when using Fileman accessing MS Word documentment located in the same domain environment as the server but does not work if I access it from home.

%config = (
root_dir => "c:/netscape/suitespot/docs/n21/demo",
logfile => "c:/netscape/suitespot/docs/n21/fileman.log",
password_dir => "c:/netscape/suitespot/docs/fileman/fileman/pass",
root_url => "http://alexander/n21/demo",
bin_url => "file://alexander/netscape/suitespot/docs/n21/demo",
script_url => "http://alexander/cgi-shell/fileman.pl",
icondir_url => 'http://alexander/n21/icons',
use_flock => 1,
allowed_space => 15000,
max_upload => 500,
show_size => 1,
show_date => 1,
show_perm => 0,
show_icon => 1,
show_pass => 0,
version => 0'


%icons = (
'gif jpg jpeg bmp' => 'image2.gif',
'txt lis dup rpt bld' => 'quill.gif',
'cgi pl' => 'script.gif',
'zip gz tar' => 'uuencoded.gif',
'htm html shtm shtml' => 'world1.gif',
'wav au mid mod' => 'sound1.gif',
'doc' => 'word.gif',
'pdf' => 'pdf.gif',
'wpd mem ver wo' => 'wp.gif',
folder => 'folder.gif',
parent => 'back.gif',
unknown => 'unknown.gif'
);





# Binary Files.
else {
$fileicon = &get_icon($fullfile) if ($config{'show_icon'});
$graphic{$file} = qq~ <tr>\n~;
$graphic{$file} .= qq~ <td><b><a href="$config{'bin_url'}/$working_dir$file"><img src="$fileicon" align=middle border=0></a></td> \n~ if ($config{'show_icon'});
# 09 Sep 99 $graphic{$file} .= qq~ <td><b><img src="$fileicon" align=middle border=0></a></td> \n~ if ($config{'show_icon'});
$graphic{$file} .= qq~ <td><a href="$config{'bin_url'}/$working_dir$file"><font color=blue>$file</font></a></b></td> \n~;
# 09 Sep 99 $graphic{$file} .= qq~ <td><font color=blue>$file</font></a></b></td> \n~;
$graphic{$file} .= qq~ <td><b><tt><a href="javascript:changePermissions('$file')"><font color="gray" size=1>$fileperm</font></a></b></td> \n~ if ($config{'show_perm'});
$graphic{$file} .= qq~ <td><b><tt><font size=1>$filedate</font></tt></b></td> \n~ if ($config{'show_date'});
$graphic{$file} .= qq~ <td><b><tt><font size=1>$filesize</font></tt></b></td> \n~ if ($config{'show_size'});
$graphic{$file} .= qq~ <td><br></td>
<td><b><a href="javascript:deleteFile('$file')"><font color=red>delete</font></a></b></td>
<td><b><a href="javascript:renameFile('$file')"><font color=purple>rename</font></a></b></td></tr>
~;
}
}
foreach (sort keys %directory) {
print $directory{$_};
}
foreach (sort keys %text) {
print $text{$_};
}
foreach (sort keys %graphic) {
print $graphic{$_};
}


The Binary Files code was slightly modified to reference the %config (bin_url)....this fix works for users inside the domain only.

Please, what can I do to fix this problem? The ultimate goal is to have and files accessible to all internet users.

Very respectfully,

Linda Corum
Quote Reply
Re: Unable to opening Binary Files??? In reply to
I really need some help and a quick resolution to this question.....lcorum

------------------