Forum: Ruby Tar2RubyScript: Path to original executable & browser issues

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
D78cd366e5836bdc86d230736743d885?d=identicon&s=25 Bart Meyers (bartm85)
on 2007-03-27 12:20
Getting the path to the original executable is possible with the script
described here:
http://www.erikveen.dds.nl/tar2rubyscript/index.html#3.2.0

I work with a rails application that consist of a executable and some
loose files (images, movies) on a dvd. With the above-mentioned script I
can reach the absolute path (ie a path to the dvd) to these files by
using "oldlocation". Great!

However, my application runs through localhost and most browsers treat
this address like any other internet address, with all security options
on. This means, among other things, that the browser will not
execute/render/show files whos path is an _absolute_ path to a file on
my system. Otherwise, any internet site could execute any file on my
system.
In many browsers, we can just add local host to a list of safe sites,
but I don't want every user of my application to have to change their
browser's settings.

So, is there any way to solve this problem? Maybe the path can be made
"relative", if it can have the prefix "http://localhost:3000/", so the
browser thinks this is just another path "to a file on that particular
server"?

Any ideas on this browser problem?

Bart
This topic is locked and can not be replied to.