Questions tagged [absolute-path]

global address for a file, independent from the working directory of the calling process

An absolute (or full) path is the general form of the name of a file or directory that specifies a unique location in a file system. An absolute path contains the root directory and all other subfolders in which the requested file or folder is contained.

833 questions
6
votes
1 answer

Relative img src is resolved as absolute... what am I missing?

In my project users can enter the URL of a website and the system goes and fetches all images from this website. Because the src of the image can be relative, the system "normalizes" it, so: an image with src="http://host.com/image1.png" becomes…
Manuel Meurer
  • 3,238
  • 6
  • 35
  • 50
6
votes
6 answers

Android: absolute location of External sd-card

I have a very simple question but so far I am unable to find an answer of this question. "Is there any way of finding the absolute path of INTERNAL STORAGE DIRECTORY and EXTERNAL STORAGE DIRECTORY(SDCARD) in Android?" Please don't recommend using…
Farhan
  • 3,206
  • 14
  • 49
  • 62
6
votes
1 answer

How can I display the current url in swagger ui?

I would like to display the current url, eg.: https://{hostname}/{pathname}..., where I am running the swagger ui on instead of a hardcoded relative path, accordingly. Is there any possible solution to do so at least to get the current hostname?…
pink_panda
  • 100
  • 1
  • 6
6
votes
1 answer

Convert Relative Path to Absolute Path

I am trying to open a Help.txt file in windows Forms using a linkLabel. However unable to convert from absolute to relative path. First, I try to get the absolute path of the exe file. Which is successful. Second, get only directory of the exe file.…
Philo
  • 1,931
  • 12
  • 39
  • 77
6
votes
2 answers

Absolute to relative path (Eclipse, JSP)

I am making a web application in Eclipse (JSP) and use Tomcat as a server (integrated into Eclipse). I have to create the object below and specify the path to configuration file. This absolute path is working great: Store store =…
Aliens
  • 984
  • 3
  • 14
  • 23
6
votes
6 answers

how to get absolute path for a image in drupal?

I have some images in drupal/sites/default/files/images/. How can I get the absolute path for an image like abc.jpg placed in this directory?
Mohit Jain
  • 43,139
  • 57
  • 169
  • 274
6
votes
1 answer

Is os.path.expanduser("~/x") equivalent to os.path.abspath(os.path.expanduser("~/x"))?

In Python, can I be sure the expanded user call will be an absolute path if the path has "~" in it? For example, is this expression always true? path = '~/.my_app' os.path.expanduser(path) == os.path.abspath(os.path.expanduser(path))
Joe
  • 16,328
  • 12
  • 61
  • 75
6
votes
3 answers

Flask static file to absolute path

Is there a flask function or a simple way to convert a static file path to it's absolute file path on disk? For example "/static/css/style.css" needs to return the absolute path for style.css based on the static folder defined in the app or…
kefeizhou
  • 6,234
  • 10
  • 42
  • 55
6
votes
2 answers

get all absolute paths of files under a given folder

I need to hold in memory all absolute paths of file names under a given directory. myDirectory.list() - retrieves String[] of file names only (without their absolute paths). Don't want to use File Object since it consumes more memory. Last thing - I…
user1025852
  • 2,684
  • 11
  • 36
  • 58
6
votes
3 answers

Error while set up absolute image path in QML/QT (under Windows)

under windows i can not load images with a absolute file path in QML. Everytime i get the following error: QML Image: Cannot open: "file//d/folder/image1.jpg" Under Ubuntu it works perfect. The image is set dynamic by this code: Image { id:…
501 - not implemented
  • 2,638
  • 4
  • 39
  • 74
6
votes
4 answers

What Perl module(s) do I use to obtain an absolute path (including filename) from a relative one on Windows?

I can only imagine I'm not searching correctly; this seems like an obvious question to be asked here. My apologies if this is a duplicate. I'm writing a Perl program that will take a filename as a command-line argument. I need to convert the…
romandas
  • 4,086
  • 7
  • 29
  • 33
6
votes
3 answers

netbeans : add library permanently

I work in a group project and after every checkout I have to remove and add the javamail api..(because the path is relative) how can i make it IN the Project folder? This is how i add the library : right click on librarys folder Add/jar…
darkrain
  • 1,025
  • 4
  • 14
  • 23
5
votes
1 answer

Absolute ("/foo") and relative ("../foo") file names. What is the "foo" category called?

There are three types of file names First (rooted below some kind of "current working directory") ../foo ./foo bar/foo # really in this group? And (rooted in an absolute path, independent of the CWD) /foo /bar/foo And (independent of the CWD and…
Johannes Schaub - litb
  • 496,577
  • 130
  • 894
  • 1,212
5
votes
7 answers

How to generate absolute URL path to a script file?

This is almost same question as this I need to get ABSOLUTE url to my script. For example, I have this structure http://mydomain.com/downloads/games/freegame_222/ajax.php My application root would be in freegame_222/ but, how can I "build" absolute,…
genesis
  • 50,477
  • 20
  • 96
  • 125
5
votes
2 answers

java.io.FileWriter: Get the path of File created

I have created an CSV file using java.io.FileWriter and its creating the file in my workspace but I want to display the location (absolute path) of the path where file is created. I know we can use file.getAbsolutePath() if we have created file…
user8268874