Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

pointer to another file

Status
Not open for further replies.

revit

Programmer
Oct 27, 2001
36
IL
i need to create an option of downloading a file from a server. the problem is that the file is kept in a directory that the user cannot access. thats why i want to make a link from a public_html dir to the file that the user can download.
i heard about the ln option but i did'nt find an example of it's use.

i'll appriciate it if someone will help me find one.
thanks in advane
 
ln -s sourcefile target

where sourcefile is the original file (the one the users' can't see)

and target is the link you want to create in the public directory.

NB: It's best to supply the full path names for both the sourcefile & the target.

HTH TandA

One by one, the penguins steal my sanity.
 
Thanks! i tried it and a link called target@ was created.
my question now is: i want to accesss this link- when i write just path/target i got a message saying : the file does'nt exist...
thanks again
 
OK,

so, assuming you are in the directory where target resides and ls target shows target@ - does

ls -l target (note the -l) show target -> /path/source ?

Assuming source is a text file, what happens if you cat /path/source and is it the same if you cat target ??? TandA

One by one, the penguins steal my sanity.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top