Accessing Network Resources When Logged Off - IIS
bkiahg
created: 2004-06-14 13:19:50
Hello Monks,

I am trying to keep a menu across servers. It's an include file and I need a way to access it like a mapped drive when the server is logged off. Is there any modules that perform this, and/or what direction should I go? It's a 2000 server trying to access a file on a 2003 server, also running IIS. I've tried.
open(MENU, 'http://servername/global/admin_menu.inc') or die "$!";
open(MENU, '\\servername\global\admin_menu.inc') or die "$!";
open(MENU, '\\servername\share_name\global\admin_menu.inc') or die "$!";
open(MENU, '//servername/global/admin_menu.inc') or die "$!";
while () {print}
close MENU or die "$!";
Any guidance is greatly appreciated.
Re: Accessing Network Resources When Logged Off - IIS
created: 2004-06-14 13:30:58
Your logic above is broken; if any attempt succeeds, you undo it by trying another method. If you don't care about trying a lot of possibly broken path alternatives, you could do this:
open(MENU,  $bestpath  ) or
open(MENU,  $nextbest  ) or
open(MENU,  $worseway  ) or
open(MENU,  $fallback  ) or die "No way to reach it!";

do_stuff_with MENU;

close(MENU) or die "Scary failure trying to close it!";
If you're just asking what the right syntax would be for a UNC path, it's \\netbioshost\sharename\path\to\file.ext.

--
[ e d @ h a l l e y . c c ]

Re^2: Accessing Network Resources When Logged Off - IIS
created: 2004-06-14 13:45:11
Those were just the different combinations I tried. I didn't use them all at the same time. Sorry for the confusion.

Update: Thanks halley the UNC path did the trick.

perlmonks.org content © perlmonks.org and bkiahg, halley

prlmnks.org © 2006 edmund von der burg (eccles & toad)

v 0.03